I've completed my truffle Dapp, the contracts are deployed to the Ropsten test network and my web code talks nicely to them, it works great from http://localhost:8080/ when I do an npm run dev.

I now want to put it onto a live webserver, still connected to Ropsten, no code changes, just the built code that is running on localhost in my browser.

How do I do a build for deployment to a webserver?

  • Did you do it? If yes, can you please answer the question? @kris Commented Feb 8, 2018 at 4:36
  • npm run build Builds the Dapp into /build
    – kris
    Commented Feb 8, 2018 at 7:37

1 Answer 1


$ npm run build

Builds the Dapp into /build
You may need to then also copy over static resources, like /images

(Thanks to : http://truffleframework.com/tutorials/building-testing-frontend-app-truffle-3)

  • @Down-voters - please provide a better answer if you have one
    – kris
    Commented Nov 28, 2017 at 3:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.