Coding for Beginners: CSS Basics #41— The Hero-Image and How to Use it

Maribel Gray on YouTubeWatch on YouTube

SaveMark complete

Sign in to save videos and track what you’ve finished.

BeginnerDesign Engineering3 min

About this video

A short beginner lesson on building a hero image in CSS, using a header background with background-size cover, centred position, a set height and a fallback colour. It is aimed at designers learning basic HTML and CSS.

What you’ll learn

  • Set a header background image with a fallback colour and fixed height
  • Use background-position and background-size cover to fill a hero area
  • Position a heading over a hero image with relative and absolute positioning