Quick Tip: How to Properly Format a WordPress Theme Stylesheet

When creating a WordPress theme whether that is for personal or client use or for release to the public as a free theme or commercial theme, there is a correct way to format it with certain information that WordPress requires. Obivously you need the theme name, theme author etc as these are displayed when you upload the theme in your WordPress admin area. There is also a number of other pieces of information that you can include, and these are required when submitting your theme to the WordPress directory.

Web Hosting

Here is a boilerplate stylesheet which will show you how to properly format a WordPress theme stylesheet :

/*
Theme Name: wplift
Theme URI: http://underscores.me/
Author: Underscores.me
Author URI: http://underscores.me/
Description: Description
Version: 1.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: wplift
Domain Path: /languages/
Tags:

This theme, like WordPress, is licensed under the GPL.
*/

You will see a section for “Tags” which you can place anything you like here, if submitting to the directory then there are just a few you can choose from, listed here. Correctly tagging your theme with the relevent options will help people when searching in the directory.

The theme URI is a link to your theme’s homepage on your own site where you can provide more information about the theme. The Description is the text which will appear on the listing and is what people will see when they upload your theme.

Resources: Underscores Starter Theme and Theme Development Codex

Oli

Oli

Oliver Dale is the founder of Kooc Media, An Internet Company based in Manchester, UK. I founded WPLift and ThemeFurnace, find out more on my Personal Blog. Thanks!