Title: Changing WordPress Website Logo
Last modified: January 29, 2021

---

# Changing WordPress Website Logo

 *  [hpsingh](https://wordpress.org/support/users/hpsingh/)
 * (@hpsingh)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/changing-wordpress-website-logo/)
 * Hi,
    I need to change my WordPress logo in the header. I have tried all the tips
   and techniques to change it but noting helps. I have changes the site identity,
   header and event inserted the logo in theme options but nothing worked. The theme
   I am using is Crown and have downloaded from Envato Elements. Since my subscription
   of one year has been expired with Envato I can not ask them for the help
 * I am also sharing my header.php code here
 *     ```
       <?php
       /**
        * The header for our theme
        *
        * @since 1.0
        * @version 1.0
        */
   
       ?>
       <?php if  (!crown_has_request_pagination_ajax()): ?><!DOCTYPE html>
       <html <?php language_attributes(); ?>>
       <head>
       <meta charset="<?php bloginfo( 'charset' ); ?>">
       <meta name="viewport" content="width=device-width, initial-scale=1">
       <link rel="profile" href="http://gmpg.org/xfn/11">
   
       <?php wp_head(); ?>
       </head>
       <body <?php body_class(); ?>>
       	<?php
       	do_action('crown_before_page_wrapper');
       	$site_wrapper_classes = apply_filters('crown_site_wrapper_classes', array('site-wrapper'));
       	?>
       	<!-- Open Wrapper -->
       	<div id="site-wrapper" class="<?php echo esc_attr(join(' ', $site_wrapper_classes))?>">
       		<?php
       		/**
       		 * @hooked crown_template_header - 10
       		 */
       		do_action('crown_before_page_wrapper_content');
       		?>
               <?php endif; ?>
               <?php $wrapper_content_classes = apply_filters('crown_wrapper_content_classes',  array('wrapper-content', 'clearfix')); ?>
   
       		<div id="wrapper_content" class="<?php echo esc_attr(join(' ', $wrapper_content_classes))?>">
       			<?php
       			/**
       			 * @hooked  crown_template_wrapper_start - 10
       			 */
       			do_action('crown_main_wrapper_content_start');
       			?>
       ```
   
    -  This topic was modified 5 years, 4 months ago by [Yui](https://wordpress.org/support/users/fierevere/).
      Reason: please use CODE button for code formatting
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fchanging-wordpress-website-logo%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 4 replies - 1 through 4 (of 4 total)

 *  [nicolasrz](https://wordpress.org/support/users/nicolasrz/)
 * (@nicolasrz)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/changing-wordpress-website-logo/#post-13980747)
 * Hello !
    your logo come from [https://crown.g5plus.net/wp-content/uploads/2019/08/logo-dark.png](https://crown.g5plus.net/wp-content/uploads/2019/08/logo-dark.png)
   I think it’s auto generated by some php function.
 * I can’t tell which one without modify or look more code.
    But you can use use
   a little “hack”.
 * Add a javascript code in your page (in the header ? )
 * `document.getElementsByClassName("site-logo")[1].src="here put url of you logo.
   png"`
 *  Thread Starter [hpsingh](https://wordpress.org/support/users/hpsingh/)
 * (@hpsingh)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/changing-wordpress-website-logo/#post-13981279)
 * Thank you [@nicolasrz](https://wordpress.org/support/users/nicolasrz/)
    could
   you please let me know exactly where (below which line) I can add this code? 
   thanks in advance
 *  Thread Starter [hpsingh](https://wordpress.org/support/users/hpsingh/)
 * (@hpsingh)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/changing-wordpress-website-logo/#post-13981288)
 * Kindly have look in to these codes I have found on the homepage of theme editor
 * `## Header
    ————————————————————–*/ .site-header { min-height: 80px; -webkit-
   box-shadow: 0px 0px 15px 5px rgba(125, 125, 125, 0.1); box-shadow: 0px 0px 15px
   5px rgba(125, 125, 125, 0.1); } .site-header .site-navigation { display: -ms-
   flexbox; display: flex; -ms-flex: 1 1 auto; flex: 1 1 auto; -ms-flex-pack: end;
   justify-content: flex-end; } .site-header .site-navigation .site-menu { -ms-flex-
   item-align: center; align-self: center; } .site-header .site-navigation + .search-
   form-wrapper { margin-left: 1.5rem; } .site-header .search-form-wrapper { -ms-
   flex-item-align: center; align-self: center; margin-bottom: 0; margin-left: auto;}.
   site-header .search-form-wrapper > span { cursor: pointer; margin-bottom: 0; 
   letter-spacing: 0.03em; line-height: 1; display: -ms-flexbox; display: flex; }.
   site-header .search-form-wrapper .search-form { position: absolute; display: 
   none; right: 0; top: 100%; z-index: 1099; background-color: #fff; border: solid
   1px; } .site-header .search-form-wrapper .search-form input { width: 210px; border:
   none; font-size: 0.875rem; } .site-header .search-form-wrapper .search-form button{
   display: none; } .site-header .menu-toggle-button { display: none; position: 
   absolute; top: 25px; left: 0; }
 * .site-header-content {
    width: 100%; position: relative; display: -ms-flexbox;
   display: flex; -ms-flex-wrap: wrap; flex-wrap: wrap; }
 * .menu-horizontal {
    margin: 0; padding: 0; list-style: none; display: -ms-flexbox;
   display: flex; -ms-flex-wrap: wrap; flex-wrap: wrap; } .menu-horizontal .menu-
   item { position: relative; } .menu-horizontal .menu-item > a { display: -ms-flexbox;
   display: flex; -ms-flex-align: center; align-items: center; text-transform: uppercase;
   font-family: “Poppins”; font-weight: 600; font-size: 0.75rem; letter-spacing:
   0.03em; line-height: 2.166667; padding: 27px 0; color: inherit; text-decoration:
   none; -webkit-transition: padding 0.3s, color 0.3s; transition: padding 0.3s,
   color 0.3s; } .menu-horizontal .menu-item > a:focus { outline: none; } .menu-
   horizontal .menu-item.x-active > .sub-menu, .menu-horizontal .menu-item:hover
   > .sub-menu { display: block; } .menu-horizontal .menu-item-has-children > a .
   caret { margin-left: 0.5rem; line-height: 1; } .menu-horizontal .menu-item-has-
   children > a .caret:before { content: “”; font-family: “Font Awesome 5 Pro”;}.
   menu-horizontal .sub-menu { display: none; position: absolute; left: 100%; top:
   0; min-width: 190px; list-style: none; padding: 15px; margin: 0; -webkit-box-
   shadow: 0 1px 5px 0 rgba(0, 0, 0, 0.1); box-shadow: 0 1px 5px 0 rgba(0, 0, 0,
   0.1); font-family: “Poppins”; background-color: #1b1b1b; color: #fff; z-index:
   1099; } .menu-horizontal .sub-menu .menu-item { border-bottom: solid 1px #1b1b1b;}.
   menu-horizontal .sub-menu .menu-item > a { padding: 0.375rem 1rem; font-size:
   0.75rem; line-height: 1.5; text-transform: none; } .menu-horizontal .sub-menu.
   menu-item > a:hover { background-color: #242424; color: #999; } .menu-horizontal.
   sub-menu .menu-item-has-children > a .caret { margin-left: auto; } .menu-horizontal.
   sub-menu .menu-item-has-children > a .caret:before { content: “”; } .menu-horizontal
   > .menu-item { display: -ms-flexbox; display: flex; } .menu-horizontal > .menu-
   item + .menu-item { margin-left: 1.5rem; } .menu-horizontal > .menu-item > .sub-
   menu { top: 100%; left: 0; } .menu-horizontal span.x-menu-link-text { display:-
   ms-flexbox; display: flex; -ms-flex-align: center; align-items: center; -ms-flex:
   1 1 auto; flex: 1 1 auto; }
 * .site-branding {
    padding: 8px 2rem 8px 0; display: -ms-flexbox; display: flex;-
   ms-flex-align: center; align-items: center; } .site-branding .site-description{
   display: none; margin: 0; } .site-branding.has-logo .site-title, .site-branding.
   has-logo .site-branding-text { display: none; } .site-branding .custom-logo-link
   img { display: block; max-height: 64px; width: auto; }
 * .site-branding-text .site-title {
    font-size: 1.5rem; font-weight: 700; margin-
   bottom: 0; line-height: 64px; } .g5core-search-form input[type=search]:-moz-placeholder{
   color: #b6b6b6; } .g5core-search-form input[type=search]::-moz-placeholder { 
   color: #b6b6b6; } .g5core-search-form input[type=search]:-ms-input-placeholder{
   color: #b6b6b6; } .g5core-search-form input[type=search]::-webkit-input-placeholder{
   color: #b6b6b6; } .g5core-search-form button { color: #b6b6b6; }
 * .g5core-header-navigation .g5core-search-form input[type=search] {
    height: 40px;}.
   g5core-header-navigation .select2-container–default.select2-container–default.
   select2-selection–single .select2-selection__arrow, .g5core-header-navigation.
   select2-container.select2-container .select2-selection–single { height: 40px;}.
   g5core-header-navigation .select2-container–default.select2-container–default.
   select2-selection–single .select2-selection__rendered { line-height: 38px; } .
   g5core-header-navigation .g5shop__search-product-cat select { height: 40px; }
 * .g5core-search-popup .g5core-search-form input[type=search] {
    border-bottom-
   color: #999; background-color: transparent; } .g5core-search-popup .g5core-search-
   form input[type=search]:focus { border-bottom-color: #fff; }
 * .x-mega-sub-menu {
    text-align: left; padding: 25px 0 0 0; } .x-mega-sub-menu.
   wpb_column + .wpb_column { border-left: solid 1px #2a2a2a; } .x-mega-sub-menu.
   gel-heading-title { color: #fff; font-size: 12px; letter-spacing: 0.05em; text-
   transform: uppercase; padding: 0 16px 15px; margin-bottom: 0; } .x-mega-sub-menu.
   gel-list .gel-list-item { font-size: 12px; line-height: 1.5; padding: 6px 16px!
   important; -webkit-transition: background-color 0.3s, color 0.3s; transition:
   background-color 0.3s, color 0.3s; } .x-mega-sub-menu .gel-list .gel-list-item:
   hover { background-color: #242424; color: #999; } .x-mega-sub-menu .gel-list 
   a { -ms-flex: 1 1 auto; flex: 1 1 auto; }
 * .g5core-menu-popup .x-mega-sub-menu .wpb_column + .wpb_column {
    border-left-
   width: 0; } .g5core-menu-popup .x-mega-sub-menu .gel-list .gel-list-item:hover{
   background-color: transparent; } .g5core-menu-popup .x-mega-sub-menu .gel-list
   a { -ms-flex-positive: 0; flex-grow: 0; }
 * .toggle-icon {
    width: 24px; height: 24px; } .toggle-icon > span:before { top:
   6px; } .toggle-icon > span:after { top: -6px; }
 * [@media](https://wordpress.org/support/users/media/) only screen and (max-width:
   991px) {
    .site-header { background-color: #fff; } .site-header .menu-toggle-
   button { display: -ms-flexbox; display: flex; }
 *  .site-branding {
    margin: auto; padding: 8px 0; height: 80px; }
 *  .site-header .site-navigation {
    display: none; width: 100%; border-top: solid
   1px #ececec; -ms-flex: 0 0 100%; flex: 0 0 100%; }
 *  .site-header .search-form-wrapper {
    position: absolute; top: 0; right: 0; font-
   size: 24px; padding: 28px 0; }
 *  .site-menu {
    margin: 0.5rem 0; }
 *  .site-menu .menu-horizontal {
    display: block; } .site-menu .menu-horizontal.
   menu-item { display: block; } .site-menu .menu-horizontal .menu-item + .menu-
   item { margin-left: 0; } .site-menu .menu-horizontal .menu-item > a { display:
   inline-block; padding: 0.625rem 0; font-size: 1rem; } .site-menu .menu-horizontal.
   menu-item:hover .sub-menu { display: none; } .site-menu .menu-horizontal .menu-
   item-has-children > a .caret { position: absolute; top: 0; right: 0; padding:
   0.625rem 0.75rem; } .site-menu .menu-horizontal .menu-item-has-children > a .
   caret:before { content: “”; } .site-menu .menu-horizontal .menu-item-has-children
   > a .caret.in:before { content: “”; } .site-menu .menu-horizontal .sub-menu {
   position: static; border: none; padding: 0; background-color: transparent; color:#
   1b1b1b; box-shadow: none; } .site-menu .menu-horizontal .sub-menu .menu-item {
   border-bottom: none; padding-left: 1.5rem; } .site-menu .menu-horizontal .sub-
   menu .menu-item > a { text-transform: none; display: inline-block; padding: 0.5rem
   0; font-size: 1rem; } .site-menu .menu-horizontal .sub-menu .menu-item > a:hover{
   background-color: transparent; }
 *  .x-mega-sub-menu {
    padding-top: 15px; } .x-mega-sub-menu .gel-heading-title{
   padding-top: 20px; padding-bottom: 5px; } .x-mega-sub-menu .wpb_column:last-child{
   padding-bottom: 20px; } } .g5core-header-above .g5core-header-inner, .g5core-
   header-bellow .g5core-header-inner { min-height: 80px; }
 * .header-gel-btn-outline a.btn-outline + a {
    margin-left: 15px; }
 * .header-contact-text p {
    display: inline-block; margin-bottom: 0; font-size:
   0.6875rem; font-weight: 600; } .header-contact-text p span { font-weight: 600;
   padding-right: 0.1875rem; } .header-contact-text p + p { padding-left: 2.1875rem;}
 * .g5core-search-button a {
    padding: 0; border: none; }
 * .g5core-logo-site .g5core-site-branding {
    display: -ms-flexbox; display: flex;-
   ms-flex-pack: center; justify-content: center; padding: 0; width: 76px; margin-
   right: 3.125rem; }
 * .g5core-header-customize-separate .g5core-header-customize-after_menu:not(.no-
   items):before {
    content: “”; border-left: solid 1px currentColor; height: 16px;
   margin-right: 1.5rem; } .g5core-header-customize-separate .g5core-header-customize-
   before_menu:not(.no-items):after { content: “”; border-right: solid 1px currentColor;
   height: 16px; margin-left: 1.5rem; }
 * .g5core-menu-display-none ul#main-menu {
    display: none; }
 * .g5core-search-button i {
    font-weight: 600; }
 * ul.g5core-social-networks.g5core-social-networks li + li {
    margin-left: 20px;}
   ul.g5core-social-networks.g5core-social-networks a { width: auto; color: inherit;
   background-color: transparent; border-width: 0; } ul.g5core-social-networks.g5core-
   social-networks a i { color: inherit; }
 * .header-95-custom .g5core-header-inner {
    padding: 0 2.5%; }
 *  [nicolasrz](https://wordpress.org/support/users/nicolasrz/)
 * (@nicolasrz)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/changing-wordpress-website-logo/#post-13984704)
 * You should try to find the footer.php
    And inside the html part add
 *     ```
       <script>
       document.getElementsByClassName("site-logo")[1].src="here put url of you logo.png"
       </script>
       ```
   

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Changing WordPress Website Logo’ is closed to new replies.

## Tags

 * [wordpress header](https://wordpress.org/support/topic-tag/wordpress-header/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 4 replies
 * 2 participants
 * Last reply from: [nicolasrz](https://wordpress.org/support/users/nicolasrz/)
 * Last activity: [5 years, 4 months ago](https://wordpress.org/support/topic/changing-wordpress-website-logo/#post-13984704)
 * Status: not a support question

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
