Jump to content

[Share] Hide a Section on Desktop/Tablet/Mobile

Recommended Posts

To hide a specific section on Desktop or Tablet or Mobile, you can follow these steps.

#1. Install Squarespace ID Finder to find the ID of the Section you want to hide.

Quote

In my example, we have:

section[data-section-id="666a4ae7e23e2617b7e6f4ed"]

image.png.fa766a8bd7295942dba8b42bbda65740.png

#2. Use this code to hide section on Desktop:

/* Hide section on Desktop */
@media screen and (min-width:992px) {
    section[data-section-id="666a4ae7e23e2617b7e6f4ed"] {
  display: none !important;
  }
}

image.png.0fa80969b6c8a03b76a098e382b4e03e.png

#3. Use this code to hide section on Tablet:

/* Hide section on tablet */
@media screen and (max-width:991px) and (min-width:768px) {
section[data-section-id="666a4ae7e23e2617b7e6f4ed"] {
  display: none !important;
  }
}

image.png.3e91a7d9667f3ede0c7d9570215c905f.png

#4. Use this code to hide section on Mobile:

/* Hide section on mobile */
@media screen and (max-width:767px) {
section[data-section-id="666a4ae7e23e2617b7e6f4ed"] {
  display: none !important;
  }
}

image.png.3c3045efbf749000af9d19218372ab4e.png

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

Link to comment
  • Replies 0
  • Views 190
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

Posted Images

Create an account or sign in to comment

You need to be a member in order to leave a comment


×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.