Skip to main content
Back to BlogTutorial

How to Add a Favicon to WordPress (Site Icon Guide 2026)

Two ways to add a favicon to WordPress: the native Customizer Site Icon upload, and the manual link-tag method for custom themes.

August 20267 min read

WordPress has built-in favicon support called the Site Icon. For most sites you don't need a plugin or any code — just upload a square image in the Customizer. This guide covers both the easy way and the manual method for custom themes.

Method 1: The Site Icon (recommended)

This is the built-in, no-code way. It works on WordPress 4.3 and later.

  1. First, generate a 512×512 PNG from your logo (WordPress recommends a 512×512 minimum).
  2. In your WordPress dashboard, go to Appearance → Customize → Site Identity.
  3. Under Site Icon, click Select image and upload your 512×512 PNG.
  4. Crop if prompted (WordPress will guide you to a square crop).
  5. Click Publish to save.

WordPress automatically generates every size it needs (favicon, Apple touch icon, app icon) and adds the correct <link> tags to your site's <head>. No code required.

Need a 512×512 image to upload? Generate one free at Favicon.one — the ZIP includes the exact size WordPress expects.

Method 2: Manual link tags (custom themes)

If you're building a custom theme or the Site Icon doesn't cover your needs, you can add favicon files manually.

  1. Upload your favicon files (favicon.ico, PNGs, apple-touch-icon.png) to your theme folder, e.g. /wp-content/themes/yourtheme/images/.
  2. Open header.php (or use the wp_head action in functions.php) and add:
<link rel="icon" type="image/x-icon" href="<?php echo get_template_directory_uri(); ?>/images/favicon.ico">
<link rel="apple-touch-icon" sizes="180x180" href="<?php echo get_template_directory_uri(); ?>/images/apple-touch-icon.png">
<link rel="manifest" href="<?php echo get_template_directory_uri(); ?>/images/site.webmanifest">

WordPress.com vs WordPress.org

On WordPress.com, the Site Identity option lives under Settings → General in some plans, or in the Customizer on others. On self-hosted WordPress.org, it's always in Appearance → Customize → Site Identity.

My WordPress favicon isn't showing

  • Clear your cache. WordPress + caching plugins (WP Rocket, W3 Total Cache) serve stale HTML. Purge all caches and check in an incognito window.
  • Check your theme. Some older themes don't call wp_head(), so the Site Icon tags never render. Make sure <?php wp_head(); ?> is in your header.php.
  • Plugin conflict. An SEO plugin (Yoast, Rank Math) or a caching plugin may override your favicon. Check their settings.
  • Image too small. WordPress requires at least 512×512 for the Site Icon. Smaller images are rejected.

For the full troubleshooting checklist, see “Favicon Not Showing?”.

Best image size for WordPress favicons

Upload a square PNG of at least 512×512 pixels. WordPress will downscale it to generate the favicon, Apple touch icon, and app icons automatically. A bigger source image (1024×1024) is fine; just make sure it's square and high-contrast.


Generate the perfect 512×512 WordPress Site Icon from your logo — free at Favicon.one.

Ready to generate your favicon?

Upload your image and get a complete favicon package in seconds. Free, private, and processed right in your browser.