Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

How to change branch in Vercel Deployment?

I have a project deployed on Vercel, and it’s currently set to deploy from the main branch of my repository. I need to change the deployment branch to a different branch (e.g., develop).

Could someone guide me through the steps to change the branch used for deployment in Vercel? Any detailed instructions or screenshots would be highly appreciated.

I’ve looked through the Vercel dashboard and settings but haven’t been able to find a clear option to change the branch for the deployment.

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

Thanks in advance!

>Solution :

To change the branch for your deployment in Vercel, follow these steps:

Navigate to Your Project:

Log in to your Vercel account.
Go to the Vercel dashboard and select the project for which you want to change the branch.
Access Project Settings:

Click on the project name to open its details.
Go to the "Settings" tab located at the top of the page.
Modify Git Settings:

In the settings sidebar, find and click on "Git".
Under the "Git" section, you will see a dropdown labeled "Production Branch" or "Git Branch".
Click on the dropdown menu and select the branch you want to use for deployments (e.g., develop).
Save Changes:

After selecting the desired branch, make sure to save your changes.
Vercel will now use the specified branch for future deployments.
Screenshots for Reference:
Unfortunately, Stack Overflow answers typically do not include screenshots directly. However, if needed, you can refer to the Vercel documentation for visual guidance.
Additional Tips:
Ensure that your new branch is up-to-date and contains the necessary configuration files for deployment.
You can also set up preview branches if you want to test deployments from multiple branches simultaneously.
By following these steps, you should be able to change the deployment branch in Vercel with ease. If you encounter any issues, feel free to ask for further assistance!

Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading