Setting up CSS in HTML5



So it’s my first time using and I have a some .html for a website started and I wanted to start styling it in .CSS. I have no idea how to start setting up the .CSS so any advice would be great :slight_smile: thanks (btw its in HTML5 if that helps with anything?)


You could embed the CSS directly into your HTML page by typing this:

<style>your CSS here</style>

or create a new CSS file in the same directory as the HTML file and put this into the HTML file:

<style src="your file name here"></style>


FYI, @Ptolemy2002 is correct about the first example, but the second example is incorrect. If you are linking an external CSS file, use the link tag with rel="stylesheet" like so:

 <link rel="stylesheet" type="text/css" href="style.css">

As for learning CSS, I recommend W3Schools.