Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

CSS CSS Basics (2014) Fundamental Concepts The Cascade: Specificity and Source Order

Andy tran
Andy tran
7,112 Points

Confused about user Agent Style Sheet and User Style Sheet

I don't understand what the functions of Agent Style Sheet and User Style Sheet, and what is the difference between Agent Style Sheet and User Style Sheet and Author Style Sheet? one thing I know that we use external style sheet of CSS to style our HTML elements.

2 Answers

Steven Parker
Steven Parker
231,248 Points

As the developer, you are the "author", so the external style sheets you write are the "author" styles.

The browser automatically applies default styles to elements. The browser is the "agent" or "user agent".

And some browsers allow the user to specify their own styles. these would the the "user" styles.

These are all described in the Cascading Origins section of the official W3 specification.

Andy tran
Andy tran
7,112 Points

Thanks for some tips! I will check out that site.