DEV Community

Shristy
Shristy

Posted on

Steps you should follow To Deploy a file with Netlify..

Usually,when we complete our project and we want to share it with others but some people that are not arround us they can't see the output of our project,this is when Netlify comes in use.
We can deploy our project on Netlify and get a direct link/URL of our project.You may think that github is also doing the same thing so that the people from various regions can view our project but this is different on github if they want to view the output they can't but with the URL we got from Netlify.com they can easily view the output and can give their feedback.

In this blog, you can easily learn the steps for Deploying file with Netlify

Steps for creating Netlify Account

  • First you are gonna need a Netlify account.Click here

  • Create a free Netlify Account.

Steps for Deploying files from Local computer

  • Create a folder and add all your project files(HTML,CSS,Javascript).

  • Log in to your Netlify account and select Add new site button and after selecting this select Deploy Manually.

b1.png

b2.png

  • Now drag and drop the project folder on Netlify as shown in the picture.

b3.png

b4.png

  • Netlify will start the Deployment until the completion of the deployment the link will be in red colour.

b5.png

  • After the completion of the Deployment the link will be in green colour.

b6.png

  • Now if you made some changes in your project/website folder and want to update the site you can select deploys tab and select the site and drag the updated folder it will get updated in the same URL.

b7.png

b8.png

Note:The name of the main HTML file must be index.html otherwise the site won't get deployed and you will get an error.

Steps for Deploying File using git repository.

  • Make a git repository and push all the project folders.

  • Log in to Netlify and select Add new site button and then select import an existing project.

b9.png

  • Now select the Github and you will be redirected to your github account for authorization.

b10.png

b11.png

  • After authorization select the git repository that contains your project files or you can also select all your repositories.

b12.png

  • After choosing the repository, you can add custom site settings to the websiteor you can choose the default settings if the source files are present at the root of the repository, and select ‘Deploy Site’.

b13.png

  • If your project files are not present at the root directiory ,they will be at sub-directory so mention the sub-directory name in the publish directory field and then press 'Deploy site'.

  • For any other updates on the project files it will automatically get deployed again in the same URL.

  • Netlify gives your site a ceratin name, you can change that name by selecting Site setting button and giving the desired name for your site.

b15.png

After following these easy steps you completed the Deployment process now you can access your project online and can have a link that you can share with others

Conclusion

This is how you can deploy your files with Netlify.I hope you were able to understand the steps.
You can follow me on twitter for more such contents.
[https://twitter.com/Shristy_29]

Top comments (0)