Career guides · Skill guide

HTML and CSS skills
employers test in 2027

HTML and CSS are still tested in 2027 for front-end, UI and web roles because they decide whether interfaces are accessible, responsive and maintainable. Employers check semantic HTML and labelled forms, the box model and cascade, flexbox and grid, responsive layouts, and accessibility basics like focus and contrast. Expect build-this-layout tasks and markup reviews. Practise by rebuilding real pages without frameworks, and prove your basics with a verified test.

By , FounderUpdated 8 min read

Share

Quick answer: What HTML and CSS skills do web jobs test, and how do I prepare?

  1. HTML — semantic elements, headings, landmarks, forms with labels, images with alt text.
  2. CSS core — box model, cascade, specificity, inheritance, units.
  3. Layout — flexbox for one dimension, grid for two; responsive design with media and container queries.
  4. Accessibility — keyboard focus, contrast, readable text, not relying on colour alone.
  5. How it's tested — build a layout from a design, fix broken markup, explain CSS behaviour.

Key takeaways

  • Framework skills don't replace HTML and CSS; interviewers notice div soup immediately.
  • Semantic HTML is the cheapest accessibility win and a frequent interview topic.
  • Most CSS confusion comes from the box model, specificity and stacking — learn them properly.
  • Modern CSS (grid, container queries, custom properties) removes many old hacks.
  • HTML/CSS skill is the entry point to front-end, UI engineering and email development roles.

Picture a front-end task at a design agency: "Build this pricing card from the screenshot." One candidate produces a pixel-perfect card from nested divs, a clickable div for the button and fixed pixel widths. On a phone it overflows; with a keyboard the button can't be reached. Another uses a section with a heading, a list for features, a real button, grid for the layout and relative units — and it works on every screen size and with a screen reader without extra effort. HTML and CSS look simple, which is exactly why interviews use them to find careful developers.

What HTML and CSS skills do web jobs test, and how do I prepare? At a glance: HTML; CSS core; Layout; Accessibility; How it's tested.
At a glance: What HTML and CSS skills do web jobs test, and how do I prepare?

Why HTML and CSS still decide web interviews

Every web interface, however it's built, ends as HTML and CSS in the browser. Semantic HTML determines whether assistive technology and search engines understand a page; CSS determines whether layouts are responsive, consistent and maintainable. That is why front-end, UI and web roles test them directly — and why HTML/CSS sits near the top of technologies used by professional developers in Stack Overflow's 2025 survey.6

These skills are the entry point to the largest group of web jobs in India: AmbitionBox lists about 68,600 front-end developer salaries, with typical pay of ₹6.1–6.7 lakh in October 2026.7

Professional developers using HTML/CSS (Stack Overflow, 2025)
~63%
Typical front-end developer pay in India (AmbitionBox, Oct 2026)
₹6.1–6.7 lakh
The accessibility standard markup is judged against
WCAG 2.2
Layout systems to master: flexbox and grid
2

How HTML and CSS are tested

FormatExampleWhat they check
Build from a designRecreate a card, navbar or pageSemantics, layout, responsiveness
Markup review"What's wrong with this form?"Labels, buttons, headings, alt text
CSS explanation"Why isn't this z-index working?"Stacking contexts, specificity, box model
Responsive taskMake a layout work at 320 px and 1440 pxUnits, media and container queries
Accessibility checkNavigate with a keyboardFocus order and visibility

Table: How HTML and CSS are tested in interviews (editorial summary)

What a fundamentals test covers

What a fundamentals test covers: Semantic HTML; Forms; Box model and cascade; Flexbox and grid; Responsive design; Accessibility basics.
What a fundamentals test covers

Semantic HTML

Landmarks (header, nav, main, footer), heading levels, lists, buttons vs links, and alt text.

Forms

Labels tied to inputs, input types, fieldsets, required fields and error messages.

Box model and cascade

content, padding, border, margin; box-sizing; the cascade, inheritance and specificity.2

Flexbox and grid

Alignment, wrapping, gaps, grid templates and areas.

Responsive design

Fluid units, media queries, container queries, responsive images.

Accessibility basics

Visible focus, sufficient contrast and not relying on colour alone (WCAG 2.2).4

MDN's learning area and web.dev's Learn CSS course are excellent free references,13 and web.dev's Baseline tells you which modern CSS features are safe to use across browsers.5

Worked example: a form that passes review

<form>
  <label for="email">Work email</label>
  <input id="email" name="email" type="email" autocomplete="email" required aria-describedby="email-hint">
  <p id="email-hint">We'll send your invoice here.</p>

  <fieldset>
    <legend>Plan</legend>
    <label><input type="radio" name="plan" value="monthly" checked> Monthly</label>
    <label><input type="radio" name="plan" value="yearly"> Yearly</label>
  </fieldset>

  <button type="submit">Start free trial</button>
</form>

Why it passes: every input has a real label, the hint is linked with aria-describedby, the email type gives mobile keyboards and validation, autocomplete helps users, radio buttons are grouped with a legend, and a real button submits the form — keyboard and screen-reader support come free.

HTML and CSS interview questions, with how to answer them

"Explain the box model."

Each element is content plus padding, border and margin. With box-sizing: border-box, width includes padding and border, which makes layouts easier to reason about.

"Why isn't my z-index working?"

z-index only works within a stacking context and on positioned (or flex/grid) items; a parent with its own stacking context (for example, opacity or transform) can trap the child.

"Flexbox or grid for a card layout?"

Grid for the overall rows and columns of cards; flexbox inside each card to align content.

"How do you center something?"

For most cases, display: grid with place-items: center on the parent, or flexbox with justify-content and align-items.

"em vs rem vs px?"

px is absolute; em is relative to the element's font size; rem to the root font size — rem keeps sizing consistent and respects user preferences.

Links navigate to a URL; buttons perform actions. Using the right one gives correct keyboard behaviour and meaning.

"How do you make images responsive?"

max-width: 100% and height: auto, plus srcset and sizes so the browser picks the right file.

"What's the difference between display: none and visibility: hidden?"

display: none removes the element from layout and the accessibility tree; visibility: hidden keeps its space but hides it.

How HTML/CSS expectations have changed

PeriodWhat happenedWhat employers expected
2005–2010Table layouts give way to CSS; browser hacksCross-browser fixes
2011–2016HTML5 semantics, responsive design, flexboxMobile-first layouts
2017–2021CSS grid, custom propertiesModern layout without frameworks
2022–2024Container queries, :has(), cascade layersComponent-level responsive design
2025–2027AI-generated markup, accessibility regulationReviewing generated HTML for semantics and access

Table: How HTML and CSS expectations have changed (editorial summary)

Practice tasks that build the skill

  1. Rebuild three real pages — A pricing page, a blog article and a dashboard shell, with no CSS framework.
  2. Keyboard-only test — Navigate each page with Tab, Enter and Space; fix anything you can't reach.
  3. Grid layouts — Build a responsive card grid with grid-template-columns: repeat(auto-fill, minmax(...)).
  4. Specificity puzzles — Predict which rule wins in ten conflicting examples, then check.
  5. Container query card — Make one component adapt to its container width, not the viewport.
Readiness check · SOA-HTML

Could you pass the HTML and CSS Fundamentals Certification today?

Hiring managers test judgement with scenarios like this one. Answer it before you open the explanation — the test has 10 of them, 10 minutes, 70% to pass.

Which meta tag is essential for responsive pages on phones?

  1. <meta name="viewport" content="width=device-width, initial-scale=1">
  2. <meta charset="utf-8"> only
  3. <meta name="mobile" content="yes">
  4. <meta name="responsive">
Show the answer

A. <meta name="viewport" content="width=device-width, initial-scale=1"> — Without the viewport tag, phones render a zoomed-out desktop width.

  1. 01HTML
  2. 02CSS
Difficulty: Beginner

Free, no sign-up. Pass and you become a HTML and CSS Fundamentals, with a credential ID employers can verify. Every answer is explained either way.

Where HTML/CSS takes your career

Role (India)Typical payHTML/CSS's part in the job
Front-end developer₹6.1–6.7 lakhEvery interface
React developer₹5.7–6.3 lakhComponent markup and styling
PHP/WordPress developer₹4.1–4.5 lakhThemes and templates
Full-stack developer₹9.2–10.2 lakhUI side of the stack
Bar chart: Where HTML/CSS takes your career — Front-end developer: ₹6.1–6.7 lakh; React developer: ₹5.7–6.3 lakh; PHP/WordPress developer: ₹4.1–4.5 lakh; Full-stack developer: ₹9.2–10.2 lakh.
Where HTML/CSS takes your career

Table: Roles that rely on HTML and CSS and typical pay in India (AmbitionBox, October 2026; indicative)

A four-week plan

Diagram of 4 steps for a four-week plan: 1. Week 1: Semantic HTML and forms; 2. Week 2: CSS core; 3. Week 3: Layout; 4. Week 4: Accessibility and proof.
A four-week plan
  1. Week 1: Semantic HTML and forms — Landmarks, headings, labels, buttons vs links.
  2. Week 2: CSS core — Box model, cascade, specificity, units.
  3. Week 3: Layout — Flexbox, grid, responsive and container queries.
  4. Week 4: Accessibility and proof — Keyboard and contrast checks; take the HTML and CSS Fundamentals Certification.

Next: JavaScript Fundamentals, Responsive Web Design and Accessibility. Our JavaScript interview guide is the natural next read.

How HTML and CSS show up at work

  • Implementing designs — turning Figma screens into responsive layouts that match spacing and type scales.
  • Component styling — building buttons, cards and forms in a design system with consistent tokens.
  • Accessibility fixes — adding labels, focus styles and landmarks after an audit.
  • Cross-browser checks — testing layouts on mobile Safari, Chrome and older Android browsers.
  • Performance — reducing layout shifts and unused CSS.
  • Email and CMS work — writing robust HTML for email clients or content templates.

More questions interviewers ask

"What is the difference between relative, absolute, fixed and sticky positioning?"

Relative offsets an element from its normal position; absolute positions it relative to the nearest positioned ancestor and removes it from flow; fixed positions it relative to the viewport; sticky behaves relatively until a scroll threshold, then sticks.

"How do CSS custom properties help?"

They store reusable values (colours, spacing) that cascade and can change at runtime — the basis of themes and design tokens.

"What does the alt attribute do, and when should it be empty?"

It describes an image for screen readers and when images fail to load; decorative images get alt="" so assistive technology skips them.

"How do you make a site work for users who zoom to 200%?"

Use relative units, flexible layouts and avoid fixed heights so content reflows instead of overlapping or requiring horizontal scrolling.

Mistakes that cost candidates

  • Div soup with clickable divs.
  • Missing labels on form fields.
  • Fixed pixel widths that break on phones.
  • !important to win specificity fights.
  • Removing focus outlines without a replacement.

How we know

Technical references are MDN (HTML, CSS and specificity), web.dev (Learn CSS and Baseline) and W3C's WCAG 2.2; usage data from Stack Overflow's 2025 survey; pay from AmbitionBox (read October 2026). Test formats and the history table are editorial summaries. Science of Apps publishes the free certification linked here. Last reviewed October 2026.

Key terms, defined

  • Semantic HTML — markup that describes meaning, such as nav or button.
  • Box model — content, padding, border and margin around every element.
  • Specificity — the weight that decides which CSS rule wins.
  • Flexbox / grid — CSS layout systems for one and two dimensions.
  • Container query — CSS that responds to a component's container size.
  • Stacking context — a layer in which z-index values are compared.

Frequently asked questions

Do HTML and CSS still matter for developer jobs?

Yes. Every web interface ends up as HTML and CSS, whatever framework generates it. Employers test them because semantic markup affects accessibility and SEO, and CSS skill decides whether layouts are responsive and maintainable. Weak HTML/CSS is a common reason front-end candidates are rejected.

What is semantic HTML?

Using elements for their meaning — header, nav, main, article, button, label — rather than generic divs and spans. It helps screen readers, keyboard users and search engines understand the page, and often gives you behaviour like focus and keyboard activation for free.

Flexbox or grid?

Flexbox lays out items in one dimension — a row or a column — and is ideal for toolbars, navigation and aligning items. Grid handles two dimensions — rows and columns together — and suits page layouts and card grids. Real layouts often use both.

What is CSS specificity?

Specificity decides which rule wins when several match the same element: inline styles beat IDs, IDs beat classes, attributes and pseudo-classes, which beat element selectors. When specificity ties, the later rule wins. Keeping specificity low makes CSS easier to maintain.

What HTML and CSS questions are asked in interviews?

The box model and box-sizing, specificity and the cascade, positioning and z-index, flexbox vs grid, responsive techniques, semantic elements, form labels, accessibility basics, and often a task to build a layout from a screenshot.

Which jobs need strong HTML and CSS?

Front-end developers, UI engineers, web designers who code, email developers, WordPress and CMS developers, design-systems engineers and many full-stack developers.

Sources

  1. MDN Web Docs — Learn web development: HTML and CSS
  2. MDN Web Docs — Specificity
  3. web.dev — Learn CSS
  4. W3C — Web Content Accessibility Guidelines (WCAG) 2.2
  5. web.dev — Baseline: features available across browsers
  6. Stack Overflow — 2025 Developer Survey, Technology
  7. AmbitionBox — Front end Developer salaries in India (updated 24 Oct 2026)
  8. Checked October 28, 2026. Figures that change — fees, salaries, prices — are reviewed every six months; if something is out of date, tell us.
Pass it on

Know someone who'd enjoy this?

Send it to them — one tap, no sign-up. Good ideas travel best between friends.

Keep exploring

Certifications to take next

Keep exploring

Career guides for related roles

Join free

Get the ideas, not the noise.

Sign up with Google and we’ll send you short UX psychology tips by email — why people tap, stall and leave, and what to do about it. Unsubscribe anytime. Prefer something to keep? Get the free Laws of UX guide as a PDF.

Get the free Laws of UX PDFFree · no spam · unsubscribe anytime
Prove you're ready

You've read the playbook. Now prove it.

Take the free HTML and CSS Fundamentals Certification and earn HTML and CSS Fundamentals (SOA-HTML). Free, test-based certifications graded on our server. Pass and you get a founder-signed certificate with a credential ID and QR code employers can verify.

Free · SOA-HTML

Become a HTML and CSS Fundamentals.

Tests modern HTML and CSS — semantic elements, forms, accessibility basics, the box model, Flexbox, Grid, responsive design and newer features like container queries. Graded on our server, with a founder-signed certificate, a credential ID and a QR code anyone can verify.

  • Credential ID
  • QR verification
  • LinkedIn-ready
Free PDF · 74 pages · 2 editions

The Laws of UX, in one field guide

60 research-backed principles in 6 categories — what each one means, why it works on the human brain and how to use it on your own screens. Written by Sushant Singh, founder of Science of Apps, who has scaled consumer apps to lacs of users and spent 10+ years leading product across startups and digital businesses in the US, EU & India.

Pick your edition
Free. No card, no paywall — just your email.
Free PDF · 74 pages

Get Laws of UX by email

Choose your edition

You’ll also get occasional UX psychology tips. Unsubscribe anytime. Privacy policy

Free PDF · 90 pages · 2 editions

100+ Subscription Paywalls, decoded

110 real paywalls from top apps, taken apart, rated out of 5 and decoded with the Laws of UX — plus the frameworks, copy and checklists to ship your own. By Sushant Singh, founder of Science of Apps.

  • 110 paywalls rated
  • 34 Laws of UX
  • 12 frameworks

Which paywall scored 4.8 out of 5, and which scored 2.6? It’s all inside.

Pick your edition
Free. No card, no paywall — just your email.
Free PDF · 90 pages

Get 100+ Paywalls, Decoded by email

Choose your edition

You’ll also get occasional UX psychology tips. Unsubscribe anytime. Privacy policy