🌐
W3Schools
w3schools.com › css › css_examples.asp
CSS Examples
Responsive grid view Responsive grid view with breakpoints Typical breakpoints Media query orientation: portrait / landscape Hide elements on different screen sizes Change font size on different screen sizes Respect user preferences Responsive image: width property Responsive image: max-width property Responsive image on responsive webpage Background image and background-size: contain Background image and background-size: 100% 100% Background image and background-size: cover Change background image depending on browser width Change background image with HTML picture element Responsive video: width property Responsive video: max-width property Responsive video on responsive webpage Responsive framework: W3.CSS Responsive framework: Bootstrap
🌐
FreeFrontend
freefrontend.com › css-code-examples
CSS Examples
February 2, 2025 - The power of CSS Grid and Flexbox ... forms and cards, are optimized using CSS variables and pseudo-elements, ensuring easy theming and clean code. These examples serve as a versatile toolkit for solving any frontend challenge without relying on JavaScript....
Discussions

Looking for examples of css eyecandy
Full disclosure: I did a lot of work on this website, but i think it's got some nice animations throughout and I'm really proud of it. What you think? https://www.westways.co.uk/ More on reddit.com
🌐 r/web_design
17
18
August 16, 2020
HTML and CSS coding website
I use GitHub pages to host my portfolio site. Free and easy to use for static projects. There are plenty of people who go both routes. I personally don’t care for website builders at all, but I’m a software dev so a bit biased there. More on reddit.com
🌐 r/web_design
39
71
September 28, 2021
IWTL how to create my own website/webpage using HTML and CSS
I actually used Tumblr to learn html/css. It was 10 years ago but there was a way to change the theme of the page by editing its html/css code. Not sure if it's still possible. More on reddit.com
🌐 r/IWantToLearn
13
9
August 31, 2022
Can I make a website with just html and css, a website that is responsive and multiple pages
Can you make a responsive website with multiple pages with just html/css (no JavaScript)? Absolutely! You can use media queries and flex in CSS to create responsive sites. There’s actually no need for JavaScript at all. More on reddit.com
🌐 r/web_design
98
212
December 13, 2020
🌐
DevSnap
devsnap.me › css-code-examples
CSS Code Examples
Curated lists of 100% free CSS code examples.
🌐
Codeconvey
codeconvey.com › home
350+ HTML / CSS Examples with Source Code & Tutorial
Codeconvey is a blog where you can get HTML, CSS examples with source code & tutorial. You will also get free source code file & demo.
🌐
W3C
w3.org › Style › Examples › 011 › firstcss.en.html
CSS Tutorial: Starting with HTML + CSS
In HTML, hyperlinks are created with <a> elements, so to specify the color, we need to add a style rule for “a”. To differentiate between visited and unvisited links, CSS provides two “pseudo-classes” (:link and :visited). They are called “pseudo-classes” to distinguish them from class attributes, that appear in the HTML directly, e.g., the class="navbar" in our example.
🌐
MDN Web Docs
developer.mozilla.org › en-US › docs › Learn_web_development › Getting_started › Your_first_website › Styling_the_content
CSS: Styling the content - Learn web development | MDN
In the previous example, it is the space around the paragraph text. ... display: The display mode of an element (which basically refers to how it appears or is laid out on the web page). ... Add the provided CSS code to the bottom of your style.css file. Save the file and refresh your browser to see how the CSS has affected the HTML rendering. Read the provided explanation to help you understand how the CSS works. If you are feeling adventurous, experiment with changing the property values to further customize your page.
🌐
Programiz
programiz.com › css › syntax
CSS Syntax (With Examples)
<html lang="en"> <head> <link rel="stylesheet" href="style.css" /> <title>Browser</title> <style> h1,p { color: red; font-size: 20px; background-color: yellow; } </style> </head> <body> <h1>This is the heading</h1> <p>This is a paragraph</p> <div>This is a div</div> </body> </html> ... We can ...
🌐
Htmlandcssbook
htmlandcssbook.com › code-samples
HTML & CSS code samples and examples to accompany book
You can try the code for all examples in the book in your browser by clicking on the chapter numbers. Or download all the code shown in the book using the orange button. Click here for the view source example.
Find elsewhere
🌐
CodePen
codepen.io › sanjanadesai › pen › bQYRxQ
Advanced CSS Code Examples:
In CodePen, whatever you write ... goes within the <body> tags in a basic HTML5 template. If you need things in the <head> of the document, put that code here. ... The resource you are linking to is using the 'http' protocol, which may not work when the browser is using https. ↑ Insert the most common viewport meta tag · CSS preprocessors ...
🌐
GitHub
github.com › zxuqian › html-css-examples
GitHub - zxuqian/html-css-examples: A collection of HTML and CSS examples, including effects and UIs. · GitHub
Text in videos and codes are primarily in Chinese, But you can use this repository without knowing Chinese. Just read the critical part. You can use this repository for inspirations and cheatsheets. Online Demo: https://zxuqian.github.io/html-css-examples/ Each folder contains the source code of HTML and CSS examples, including:
Starred by 991 users
Forked by 375 users
Languages   HTML 61.3% | CSS 25.7% | JavaScript 13.0%
🌐
Simple.css
simplecss.org › demo
Simple.css Demo | Simple.css
This page is a demonstration of the elements that can be formatted using Simple.css. Each section includes a code block on how to include it in your site’s design.
🌐
Reddit
reddit.com › r/web_design › looking for examples of css eyecandy
r/web_design on Reddit: Looking for examples of css eyecandy
August 16, 2020 -

I've been whipping up simple html/css/Javascript sites lately as a hobby. It's been fun to try to challenge myself to get creative by making lots of different sites, and making new sites to try out different ideas.

Can you guys recommend any sites in particular that are examples of fun / creative / beautiful html/css sites?

For instance, I got into the animations part of css / javascript and am sure there have been some really cool sites people have made.

🌐
freeCodeCamp
freecodecamp.org › news › css-example-css3
The Best CSS Examples and CSS3 Examples
November 18, 2019 - CSS breakpoints are useful when you want to update styles based on the screen size. For example, from a device measuring 1200px width and above, use the font-size: 20px;, or else use the font-size: 16px;. What we have started with is from devices greater than 1200px, a common laptop screen’s width.
🌐
GitHub
github.com › mdn › css-examples
GitHub - mdn/css-examples: Code examples that accompany the MDN CSS documentation · GitHub
You can also find versions that show the same timing function used with transitions, and used with the Web Animations API. The "counter-style-demo" directory contains a demo for the @counter-style documentation. See the live demo here. The "moz-context-properties" directory contains a demo for the -moz-context-properties documentation. See the live demo here. The "editable-examples" directory contains CSS examples that are intended to be embedded in MDN pages as live editable samples.
Starred by 646 users
Forked by 834 users
Languages   HTML 80.7% | JavaScript 14.7% | CSS 4.6%
🌐
Tutorial Republic
tutorialrepublic.com › css-examples.php
CSS3 Examples - Tutorial Republic
A collection of CSS3 examples covering topics like color, background, fonts, alignment etc. to help you understand how CSS properties are used to style web pages.
🌐
Quackit
quackit.com › css › examples
CSS Examples
Free CSS examples — copy & paste code for your website.
🌐
BitDegree
bitdegree.org › learn › css-code
CSS Code Examples: Comprehensive List Of Various CSS Examples
December 14, 2018 - Set all CSS properties that make up CSS box model Compare elements with and without padding Add box-sizing: border-box to manage dimensions of certain elements Apply box-sizing: border-box to all elements at once Create an element with resizable width Create an element with resizable height Create an element with resizable width and height Disable resizing on elements that are resizable by default · The following CSS code examples show the ways to control the outline property.
🌐
MDN Web Docs
developer.mozilla.org › en-US › docs › MDN › Writing_guidelines › Code_style_guide › CSS
Guidelines for writing CSS code examples - MDN Web Docs | MDN
November 7, 2025 - Formal syntax is an integral part of MDN's CSS documentation (as an example, see the Formal syntax section on the background-image property page). Because a lot of developers are familiar with syntax in this format, it's acceptable to write pseudocode in a formal-syntax-like fashion in descriptions and examples. However, any code that is not syntactically well-formed CSS should not be marked as CSS.
🌐
MakeUseOf
makeuseof.com › home › programming › 10 simple css code examples you can learn in 10 minutes
10 Simple CSS Code Examples You Can Learn in 10 Minutes
June 28, 2021 - The background color is set with background-color, and text color with color. Padding defines the size of box---the text is padded by 10px vertically and 25px horizontally. Text-align ensures that the text is displayed in the center of the button, instead of off to one side. Text-decoration, as in the last example, removes the underline. The CSS code "display: inline-block" is a bit more complicated.