Displaying html pages along with their css file on client side

I am quite new with server side programming in general and node.js in particular. Despite the several books I read about it I still can't figure out how to display an index.html in the client side, along with its css files. Is it most common to work with a ready made index.html file or perhaps to construct it on the fly using node.js? There's a big chance I'm missing something quite major here so I'll appreciate a well-explained answer...

Thanks!

Generally, if you're using Node to create some sort of web site or web app, you don't do it directly with Node. I'm going to assume that your end goal here is the website - not your own customized HTTP server that is also capable of serving websites.

So while Node does have the http library built in for serving content over HTTP, your life will probably be a lot easier if you use one of the common libraries/frameworks designed for creating websites with both dynamic and static content, such as Express.js. Using Node directly for HTTP relies more on your knowledge of the HTTP protocol and less on your knowledge of Node or HTML.

Express.js has a very straightforward guide about how to set up a simple app. If you're serving entirely static content, you can even skip the calls to app.get() and instead just set up up express.static() to point to a directory with your index.html and CSS files in it.

This might not be the answer you're looking for - you really need to decide if you're trying to learn server-side network programming, or if you're just trying to learn how to make modern/database-driven web apps. Raw Node is (usually) network programming. Express.js and similar are webapp programming.