How to add Borders to Individual Elements/Blocks in Your Shopify Store

share

Disclosure: This post may contain affiliate links, which means I will receive a commission if you purchase through my links. There is absolutely no additional cost to you! 

Hola! We are back with another tutorial on borders! If you are looking to add borders around individual blocks then you are in the right place! We will add borders to the Image with Text and Multicolumn blocks. You can apply this same concept to other blocks in the same way.

This tutorial is piggybacking off of last week’s post on how to add section borders. So check it out if you missed it, but it’s not needed as we will go into it again here!

If you are new to using CSS, not a problem my friend! This guide is perfect for beginners. I’ll walk you through it step-by-step.✨

Below is the corresponding tutorial over on my YouTube channel. If you already watched the video then you’re already on the right track. Continue reading for all the ways to customize the CSS code, YASS their is more! 🫶🏽

Want to watch the tutorial instead? Click 👇🏽

https://youtu.be/0OCI2MfRAH0

How to add borders to different element/block types in Shopify

Begin by heading over to your Shopify admin and navigate to the “Online Store” section. From there, click on “Themes.” Locate the theme you want to apply the border too and click on “Customize.”

STEP 1: Choose the Section you want to customize (Image with Text or Multicolumn).

Once you’re inside the theme customizer, it’s time to choose the section you want to jazz up with a border.

Within the theme editor, you’ll be able to customize various aspects of your store’s design. Decide which block you want to add a border to. Once you’ve selected the section (which has the block you want to add the border too) click on the section, and scroll down to the very bottom of the editor to find the Custom CSS panel. This is where the magic happens! 

The code you add here will only affect the selected block. If you want borders on other blocks, you can simply repeat the process for each one.

How to add a border to the image in the Image with Text section in Shopify- before & after.

Image with Text Section Text Block Border:

How to add a border to the text block in the Image with Text section in Shopify- before & after
How to add a border to the columns in the Multicolumn section in Shopify- before & after

STEP 3: Click SAVE

Pssssst…. You can 📌 pin this tutorial for reference to your Shopify Board on Pinterest! 👍🏽

How to add a borders to the Multicolumn section block - in Shopify - Step by Step Tutorial
How to add a borders to the Image with Text section block - in Shopify - Step by Step Tutorial

Understanding and Customizing the Borders

The beauty of CSS is that you can play around with it to create the perfect look for your store. Here’s a breakdown of the code to help you customize it:

  • Border Property (1): This lets you choose where you want the border to appear. Here are some options:
    • Border – Border wraps around the entire section
    • border-top – Defines a top border only
    • Border-bottom – Defines a bottom border only
    • Border-left – Defines a left border only
    • Border-right – Defines a right border only
  • Border Style (2): You have the freedom to choose the type of line around your border! Play around with the following values:
    • dotted – A line that consists of dots.
    • dashed – A line that consists of dashes.
    • solid – A solid, continuous line.
    • double – Two lines are drawn around the element.
    • groove –  Adds a bevel based on the color value in a way that makes the element appear pressed into the document. The effect depends on the border-color value.
    • ridge –  Adds a bevel based on the color value in a way that makes the element appear pressed into the document. The effect depends on the border-color value.
    • inset – Adds a split tone to the line that makes the element appear slightly depressed. The effect depends on the border-color value
    • outset – Similar to inset, but reverses the colors in a way that makes the element appear slightly raised. The effect depends on the border-color value
  • Border Width (3): Want a thin border or a bold statement piece? Adjust the height (in pixels) to your liking.

  • Border Color (4): Pick a color that complements your brand’s vibe! Simply enter the hex code, and voila! You can also use RGB, and HSL color values. 

  • !Important (5): This is an optional addition. Sometimes, you might need to emphasize that your CSS rules should override any conflicting styles.

Bonus CSS Code:

Want to soften up the corners of the borders a bit?! You can easily soften the edges of your borders to create a softer feel or leave it as is for a modern look.

Tip #1: How to Round the Border Corners

You can soften the edges of the corners in 2 ways:

Option #1: Inside the Theme setting.
Within the Theme Editor go to Theme settings (top left hand side) > Content containers > Corner radius > set the radius to your preference.

Option #2: Inside the section Custom CSS:

  • Locate the Border Code:  Within your custom CSS section (as mentioned in Step 2 of the main guide), find the code you added for the border.
  • Introducing border-radius: After the last semicolon (;) enter border-radius: Xpx; Replace “X” with your desired curvature value. The higher the value, the rounder the corners will become.

This will add a 10px rounded edge to the border. Don’t forget to Save the changes.

Tip #2: How to Add Shadow to Borders

You can soften the edges of the borders in 2 ways:

Option #1: Inside the Theme settings.
Within the Theme Editor go to Theme settings (top left hand side) > Content containers > Shadow > set the Opacity, Horizontal offset, Vertical offset, and Blur your preference.

Option #2: Inside the section Custom CSS:

  • Locate the Border Code:  Within your custom CSS section (as mentioned in Step 2 of the main guide), find the code you added for the border.
  • Introducing box-shadow: After the last semicolon (;) enter box-shadow code: Xpx #hex-color; Replace “X” with your desired effect and color.

Decoding and box-shadow CSS
Here’s a breakdown of the code to help you customize it:

  • Box-Shadow Property (1): This property is used to add shadows to elements. It can take multiple values to define the different aspects of the shadow.

  • Values:
    • (2) – This is the horizontal offset of the shadow. A positive value moves the shadow to the right, and a negative value moves it to the left.
    • (3) – This is the vertical offset of the shadow. A positive value moves the shadow down, and a negative value moves it up.
    • (4) This is the blur radius of the shadow. A higher value creates a softer, more blurry shadow.
    • (5) This is the spread radius of the shadow. A positive value makes the shadow larger, and a negative value makes it smaller.
  • Play around with the values in the properties to achieve the specific shadow effect you desire. Change the offsets, blur radius, spread radius, and color to create different shadow styles.

Experiment and Have Fun with CSS

The beauty of CSS customization is how flexible it is. Feel free to experiment with different styles, heights, values, and colors until you find the perfect combination for your brand.

Here is some code to try:

You made it to the end! Create unique borders that reflect your brand and let your store stand out! Share your creations with me, I would love to see your designs, tag me on Insta @betsy_oficial/ 🤩

YOU GOT THIS!
Betsy

FAQ’s

Can I add borders to any section of my Shopify store?

Yes! You can add borders to almost any section of your Shopify store using CSS customization. Whether it’s the announcement bar, product information, or any other section where the Custom CSS box is available.

Do I need coding experience to add borders to my Shopify website?

While some basic understanding of CSS can be helpful, you don’t necessarily need any experience. This tutorial is designed for beginners, so just follow along and make sure you use the code correctly.

Will adding borders affect my website’s loading speed?

In most cases, the impact on loading speed should be minimal. Borders are relatively lightweight and shouldn’t significantly increase page load times.

What if I want different border styles for different sections?

No problem! The beauty of CSS is its flexibility. You can create separate code variations for each section to achieve the desired border styles.

Can I add borders to other elements on my Shopify store, besides sections?

Absolutely! CSS can be used to style various elements in your store, like buttons, product images, and text. However, the specific steps might differ depending on the element you’re targeting.

Related Tutorial:

How to add borders to sections in Shopify

WELCOME TO THE BLOG

Hola! I’m Betsy, so happy to have you here! I share tips, tricks, and resources to help you build an ecommerce shop you’re proud of!

JOIN THE COMMERCE CONNECTION TRIBE!

Stay up to date on the latest Shopify updates and new releases, PLUS much more delivered directly to your inbox.

Please wait...

<span style="color: #000357;">woohoo! Welcome to the tribe!</span>

No Spamming here!
Unsubscribe at any time.

Stay up-to-date

on all things ecommerce and Shopify!

Join Commerce Connection our monthly newsletter to receive all the goodies straight into your inbox. Delivered on the 1st of the month, you can expect:

Commerce Connection by Betsy Lugo Creative

Leave a Reply

Your email address will not be published. Required fields are marked *

Shopify launch checklist

Launch checklist

Everything you need to launch with confidence knowing you didn’t forget anything.