Is it better to learn HTML first and then CSS, or should I learn both simultaneously?

I’m new to web development. I’m currently pursuing HTML Fundamentals course and I’m almost done. Had I better follow all of the HTML courses (Learn HTML) or learn CSS ones at the same time ? I think it would take me quite long to have a certain level if I do one at the time but, conversely, I wish to have very strong foundations in HTML. Any advice ?

1 Like

Hi, there!

I would say that there is nothing wrong with learning them hand-in-hand. After all, HTML is used to build a webpage, but you need CSS to style it.

However, do not move too quickly when you start learning CSS. Many times I have witnessed people applying too many styles because they don’t understand inheritance and default values. Take the time to understand the intrinsic styles of each element and property, and it will help you in the long run.

Do this for both :point_up:


Beautifully said by @kirativewd.

However, I would lean more towards solidifying your knowledge with HTML before learning CSS, personally.

Focus on semantic HTML in your studies, and try to avoid using div’s if possible. Explore other tags such as <article> and <section>. If something small needs formatting, throw a <span> in there.

When you begin tackling CSS, it may benefit you to start off your CSS file with:

* {
border: 2px solid red;

The * selector targets everything on the page, and giving everything a red border will allow you to visually see the boxes and spacing on the page and you can adjust accordingly. This is temporarily, but it helped me visually see the CSS code in action. Sometimes it’s hard to see how spacing is being altered when everything is again a white background.

Hope this helps!


Think of the HTML as the Skeleton and the CSS as the Skin, the Eyes, and the hair.

I’d suggest learning HTML first and then moving to CSS so you can learn how the websites are structured and work. Once you are confident enough that you have gained enough knowledge actually to move to the styling and beautifying part of the website, then learn CSS.


This topic was automatically closed 41 days after the last reply. New replies are no longer allowed.