Skip to content
ThemesIonic — home
Troubleshooting

The Theme Is Missing the style.css Stylesheet

The zip you uploaded is not a theme, or the theme is inside it one level too deep. Marketplace downloads bundle the installable zip with documentation, and uploading the bundle is the cause nine times out of ten.

Updated 6 min read beginner

WordPress looked for style.css at the root of the zip, or inside its single top-level folder, found nothing, and stopped. The full message is "The package could not be installed. The theme is missing the style.css stylesheet." — the first sentence is the installer's generic failure, the second is the check that failed. The same condition shows up in Appearance › Themes as a Broken Themes entry reading "Stylesheet is missing." when the folder was copied in by hand. Neither means the file is absent from the theme; both mean it is not where WordPress looks. A style.css that exists but has no theme header produces a different message — "The style.css stylesheet does not contain a valid theme header." — so this one is always about where the file is, never what is in it.

Open the zip before uploading it

Unzip the download on your computer and look at what is inside. One of these shapes will match:

Inside the zip What it is What to do
style.css, functions.php, index.php … An installable theme, contents at root Upload as is
theme-name/style.css … An installable theme in one folder Upload as is
theme-name.zip, Documentation/, Licensing/, child-theme.zip A marketplace bundle Upload theme-name.zip from inside
theme-name/theme-name/style.css A zip of the parent folder Re-zip the inner folder
plugin-name.php, readme.txt A plugin Install it from Plugins › Add Plugin
index.html, css/, js/ An HTML template, not a WordPress theme Not installable

The bundle row is the common one. Theme marketplaces package the installable theme alongside documentation and sample content, and the download's name looks like a theme. Uploading it on Appearance › Themes › Add Theme › Upload Theme (Add New on older versions) produces exactly this message, because the installer finds zips and folders but no style.css. The installable file is usually named after the theme and sits at the bundle's top level, sometimes next to a child-theme zip; the marketplace theme guide shows what a typical bundle contains.

The zip-of-a-folder case

The installer descends into the zip only when it contains exactly one top-level entry and that entry is a folder. When you build a zip yourself — a child theme, a theme downloaded from a repository as source, a theme copied from another site — compressing the folder that contains the theme folder adds a level. Windows, macOS and most GUI tools do this when you right-click the parent. The result is theme.zip/theme/theme/style.css, two levels down, and WordPress inspects only the first.

Re-zip the theme folder itself so its name is the only top-level entry:

cd /path/to/themes
zip -r my-theme.zip my-theme -x '*.DS_Store'

A zip made in Finder may also contain a __MACOSX folder; WordPress skips it during extraction, so it is harmless for the install, and the exclusion above only keeps the archive tidy.

The theme installer runs a short sequence of checks and each failure has its own wording:

Message Meaning
The theme is missing the style.css stylesheet. No style.css at the root or in the single top folder
The style.css stylesheet does not contain a valid theme header. File found, but no Theme Name: line in its header comment
Template is missing. Standalone themes need to have a templates/index.html or index.php template file. … Parent theme with no index.php and no templates/index.html; older versions said "The theme is missing the index.php file."
The PHP version on your server is X, however the uploaded theme requires Y. The header's Requires PHP is higher than the server's version

The second row is what a starter kit with an empty style.css produces, and the fix there is the header, not the zip. A minimal header has Theme Name: for a parent and Theme Name: plus Template: for a child, where Template must match the parent's folder name exactly; the child theme guide shows the shape. A child theme uploaded before its parent installs: WordPress tries to fetch the parent from the theme directory, warns "The parent theme could not be found" if it is not there, and the child then appears under Broken Themes with "The parent theme is missing. Please install the … parent theme."

Fixes by install route

The check runs on every route that uses WordPress's theme installer, so the fix depends on how the zip reached the server:

  • Appearance › Themes › Add Theme › Upload Theme. Upload the installable zip, not the download. This is the route the table above assumes.
  • WP-CLI. wp theme install my-theme.zip runs the same installer and fails with the same text. Check the archive first with unzip -l my-theme.zip | head: the listing should show style.css or my-theme/style.css near the top.
  • cPanel or Plesk file manager. Extracting the zip yourself in wp-content/themes/ skips the check entirely, so an extracted bundle there produces "Stylesheet is missing." under Broken Themes instead. After extracting, open the new folder: style.css must be directly inside it.
  • SFTP or a local development tool. Copy the folder that contains style.css into wp-content/themes/. Copying the extracted bundle instead lands under Broken Themes.
  • Managed hosting dashboards. Some install themes through WordPress and show this exact message; others extract archives themselves and only show Broken Themes. The zip structure is the cause in both.

Repository downloads

A theme downloaded from a code hosting site as "source" arrives as repo-name-main.zip with the files one folder down — installable as is — but may lack a build step's output, such as compiled CSS. The structure check passes and the theme installs; what fails is the site's appearance. That is a different problem, and a theme distributed that way expects to be built before installation.

When uploading is the wrong route

A theme larger than the upload limit, or one that fails for reasons the installer does not explain, can be installed by unzipping it and copying the folder to wp-content/themes/ over SFTP. WordPress scans the folder on the next visit to Appearance › Themes and lists anything with a style.css carrying a header. If the theme is listed under Broken Themes, the message there names what is missing — the stylesheet, a template file, or the parent. WordPress also looks one folder down, so one extra level still lists; a bundle of zips and documents, or a theme two levels deep, shows as "Stylesheet is missing." The full install procedure, including this route, is in how to install a theme.

Verify

Appearance › Themes lists the theme with its name and screenshot. Activate it — or, for a child theme, confirm the parent is installed first, or the child shows as broken with a message naming the missing parent. If the error reappears on a later update uploaded the same way, you uploaded the bundle again; keep the installable zip, not the download, for next time.

Frequently asked

Because the zip you uploaded contains the theme zip, not the theme. Marketplace downloads are bundles with documentation, licensing and one or more installable zips inside. Unzip the download on your computer and upload the installable theme zip from inside it.
It is the same problem seen from the other side: a folder in wp-content/themes has no style.css at its top level, usually because a whole bundle was extracted there, or a theme ended up two folders deep (one extra level is tolerated). Put the folder that contains style.css directly in wp-content/themes and the entry disappears from Broken Themes.
The plugin version reads 'No valid plugins were found' and has the same causes: a bundle instead of the plugin zip, a nested folder, or a plugin uploaded on the theme screen. Check which installer you used.

Related guides