GeneratePress Custom CSS Snippets Every Beginner Should Know
Simple CSS tweaks can make a GeneratePress website look cleaner, more polished, and more personalized — without installing another plugin.
GeneratePress is already known for being lightweight, flexible, and performance-friendly. But when you want to make small design changes, the WordPress Customizer may not always provide the exact control you need.
That is where Custom CSS becomes useful.
In this guide, we’ll look at several beginner-friendly CSS snippets that can help you customize common parts of a GeneratePress website.
Important: Before adding CSS to a live website, test it carefully and keep a backup of your existing custom CSS.
Why Use Custom CSS with GeneratePress?
You don’t always need a page builder or additional plugin for small design changes.
Custom CSS can help you:
- Adjust spacing
- Customize buttons
- Improve headings
- Style navigation
- Change link appearance
- Improve mobile layouts
- Create cleaner content sections
- Add subtle visual effects
The goal isn’t to add lots of CSS. The goal is to use small, focused snippets that solve specific design problems.
1. Change the Site Title Font Size
If your site title looks too large or too small, you can adjust it with CSS.
.site-branding .main-title {
font-size: 32px;
}You can change 32px to the size that works best for your website.
For example:
.site-branding .main-title {
font-size: 28px;
}This is useful when you want a more compact header.
2. Add More Space Around the Main Content
Sometimes the content area can feel too close to surrounding elements.
You can add a little extra spacing:
.site-content {
padding-top: 30px;
padding-bottom: 30px;
}Avoid adding excessive spacing because it can make pages unnecessarily long.
A small adjustment is usually enough.
3. Customize Button Appearance
GeneratePress buttons can be customized with CSS to match your website’s design.
.button,
.wp-block-button__link {
border-radius: 6px;
padding: 12px 20px;
font-weight: 600;
}This gives buttons a cleaner shape and improves their visual hierarchy.
You can also add a simple hover effect:
.button:hover,
.wp-block-button__link:hover {
transform: translateY(-2px);
}Keep hover effects subtle. The goal is to improve interaction — not distract visitors.
4. Create Rounded Featured Images
If you prefer a softer visual style, you can slightly round your featured images.
.post-image img {
border-radius: 10px;
}You can increase or decrease the value depending on your design.
For example:
border-radius: 16px;works well for a more rounded appearance.
5. Improve Heading Spacing
Good typography needs enough breathing room.
You can adjust your post headings with:
.entry-content h2 {
margin-top: 35px;
margin-bottom: 15px;
}For smaller headings:
.entry-content h3 {
margin-top: 28px;
margin-bottom: 12px;
}This can make long articles much easier to scan.
6. Customize Links
You can make links more noticeable without using excessive styling.
.entry-content a {
text-decoration: underline;
text-underline-offset: 3px;
}This is particularly useful for content-heavy websites where readers need to identify links quickly.
7. Style Blockquotes
Blockquotes can make important statements stand out.
Try:
blockquote {
border-left: 4px solid #333;
padding-left: 20px;
margin: 30px 0;
font-style: italic;
}You can change the border color to match your website’s branding.
8. Add a Subtle Box Shadow to Buttons
A small shadow can give buttons more visual depth.
.button,
.wp-block-button__link {
box-shadow: 0 3px 8px rgba(0, 0, 0, 0.12);
}Don’t make the shadow too strong. Subtle effects usually look more professional.
9. Improve Mobile Spacing
A layout that looks good on desktop may feel crowded on a phone.
You can use a media query to make adjustments specifically for smaller screens:
@media (max-width: 768px) {
.site-content {
padding: 20px 15px;
}
}This lets you create a different spacing system for mobile visitors.
Get Nel Biswas Somir’s stories in your inbox
Join Medium for free to get updates from this writer.
Always check the result on an actual mobile device or responsive preview.
10. Customize the Navigation Menu
You can adjust the spacing between navigation menu items:
.main-navigation .main-nav ul li a {
padding-left: 15px;
padding-right: 15px;
}This can help create a cleaner navigation layout.
However, avoid making menu items too wide, especially on smaller screens.
11. Add a Hover Effect to Navigation Links
A simple transition can make navigation feel smoother.
.main-navigation .main-nav ul li a {
transition: color 0.2s ease;
}Then customize the hover state:
.main-navigation .main-nav ul li a:hover {
color: #0073aa;
}Replace the color with your website’s brand color.
12. Make the Footer More Compact
If your footer contains too much vertical space, you can reduce the padding:
.site-footer {
padding-top: 25px;
padding-bottom: 25px;
}Don’t reduce it too much. The footer should still have enough space to separate it from the main content.
13. Style the Search Form
A simple border radius can make the search field look more modern:
.search-form input[type="search"] {
border-radius: 6px;
}You can also add consistent padding:
.search-form input[type="search"] {
padding: 10px 14px;
}Small details like this can make a website feel more polished.
14. Prevent Images from Becoming Too Wide
For content images, you can control their appearance with:
.entry-content img {
max-width: 100%;
height: auto;
}This helps images remain responsive inside their content container.
It’s especially important for mobile users.
15. Create a Simple Highlight Box
You can create a reusable content box using a custom class.
First, add this CSS:
.highlight-box {
padding: 20px;
margin: 25px 0;
border-radius: 8px;
background: #f5f5f5;
}Then add the class to the appropriate block or element.
This can be useful for:
- Important tips
- Notes
- Warnings
- Quick takeaways
- Additional information
Where Should You Add Custom CSS?
For many WordPress setups, you can add custom CSS through:
Appearance → Customize → Additional CSS
Depending on your WordPress/GeneratePress setup, the exact customization options may vary.
Before adding multiple snippets, it’s a good idea to organize your CSS and keep notes about what each section does.
Don’t Add CSS Just for the Sake of It
One of the biggest mistakes beginners make is adding CSS for every small visual change.
More CSS doesn’t automatically mean a better website.
Before adding a snippet, ask:
Does this improve usability, readability, branding, or consistency?
If the answer is no, you probably don’t need it.
Test Your CSS on Mobile
Never test your CSS only on a desktop screen.
Check:
- Desktop
- Tablet
- Mobile
- Navigation
- Buttons
- Images
- Headings
- Forms
- Content spacing
A CSS change that looks perfect on desktop can sometimes create problems on smaller screens.
Keep Your Custom CSS Organized
As your website grows, your CSS can become difficult to manage.
Instead of putting everything together randomly, use comments:
/* Header */
.site-branding .main-title {
font-size: 32px;
}/* Buttons */
.button {
border-radius: 6px;
}/* Content */
.entry-content h2 {
margin-top: 35px;
}
This makes future maintenance much easier.
Final Thoughts
GeneratePress gives beginners a strong foundation for building lightweight and professional WordPress websites.
You don’t need dozens of CSS snippets to customize your site. A few carefully chosen rules can improve spacing, typography, buttons, navigation, images, and mobile usability.
The best approach is simple:
Start small → Test → Check mobile → Keep what works.
Once you’re comfortable with basic CSS, you can gradually move toward more advanced GeneratePress customization and create a design that feels truly your own.
What is your favorite GeneratePress CSS customization? Share it in the comments.










