How To Make Vertical Lines in Squarespace
If you’ve spent any time building a Squarespace website, you know that it’s super easy to make a horizontal line by using a line block.
But what about vertical lines?
Vertical lines can create a sense of height or grandeur. I like to use a lot of whitespace in my design. If you hold trepidation about leaving too much whitespace between paragraphs and images, try using vertical lines to create page length and indicate to the user that there is more information below.
It’s incredibly easy to do, here’s how it’s done:
Step 1: Create an HTML div
Do this by adding a code block.
In the code block, enter:
<div class="vl"></div>You can name the div class anything you want. I’m calling it “vl”, but you could call it “vertical-line”, “vert-lie,” “flibbertyjibbit…” anything. It doesn’t matter what you call it.
Step 2: Use CSS to Style the div Into a Vertical Line
In the your site’s custom CSS (Design > Custom CSS), use this code to style the div:
.vl {
border-left: 2px solid #000000; // defines the width, style and color of the line (change the hex code [#303030] to match your site).
height: 100px; // defines the length of the line.
position: absolute;
left: 50%; //move the line to the middle (50% of the page width)
margin-left: -1px; //half the width of border witdth to ensure the line is precicely centered on the page.
top: 0;
}
What’s happening:
If you named the div class “vl,” you write “.vl” to modify the div you created. If your div class is named “vertical-line,” you would write “.vertical-line” before the opening curly bracket ( { ).
Optional:
If you want the colour or style of a vertical line to be different from page to page, you’ll need to place the CSS from step 2 in the “Advanced” section of the page options { ⚙️> Advanced) to apply it to one specific page.
If you need to place the CSS in the page’s advanced section, you need to write the code a little bit different. You’ll need to put the code between <style> tags, so the CMS knows that it’s CSS.
Write it like this:
<style>
.vl {
border-left: 2px solid #303030; // defines the width, style and color of the line (change the hex code [#303030] to match your site).
height: 100px; // defines the length of the line.
position: absolute;
left: 50%; //move the line to the middle (50% of the page width)
margin-left: -1px; //half the width of the border witdth to ensure the line is precicely centered on the page.
top: 0;
}
</style>
Use spacer blocks to keep vertical lines from overlapping other content, and make sure it looks ok on mobile too.
If you want to take your Squarespace website to the next level, visit the code shop for unique modifications that will set you apart. Interested in hiring a Squarespace designer? Explore my portfolio below.
Related Articles:
Learn how to turn the inset border on a Squarespace section into a blurred image frame using just 6 lines of custom CSS. Step-by-step tutorial with a code generator.
Create a vertical scrolling testimonial carousel to any Squarespace site. Includes a live code generator where you can type in your own reviews, customize colors, speed, and card styles, and copy the finished code in one click.
Uploaded a video to Squarespace but can't find a way to download it back? Here's a quick workaround to retrieve your hosted video files when the download button is missing.
Learn how to add quizes, polls, and surveys to your Squarespace website without code using Opinion Stage. A free tool to turn quizes and polls into lead generators.
Create anchor links in Squarespace 7.1 without coding! Learn to make smooth scrolling internal links for same-page navigation, links to other pages, and SEO-friendly anchor links. Get solutions for unsupported sections too.
A complete guide to the 2026 Squarespace Circle program changes, including how to qualify for Gold and Platinum status, earn points, and unlock exclusive discounts.
Create a typewriter effect header with a blinking cursor on your Squarespace site using one simple code block.
Add a 'View Project' button overlay to your Squarespace portfolio thumbnails. This code snippet is an easy plug-and-play solution to enhance your Squarespace website design.
Learn how to write original content as a Squarespace designer without relying on AI-generated templates. This guide covers a five-step process for creating blog posts that keep your unique voice while using AI as a helpful tool.
Add a collapsible floating side navigation menu to your Squarespace site with this code snippet. Keep links accessible without clutter, customize icons and colors, while being fully responsive. Follow the step-by-step guide to integrate it seamlessly.
Learn how to customize the default 'Sign up for News and Updates' text in Squarespace forms with a simple JavaScript snippet. This quick guide will help you align your forms with your brand’s tone and messaging, boosting engagement and maintaining consistency.
Discover Generative Engine Optimization (GEO) and learn how to rank in AI-generated search results from tools like ChatGPT and Google Gemini. Build a strong SEO foundation, optimize for informational queries, and adapt to AI-driven search behavior for future-proof visibility.
Learn how to reposition your Squarespace header to the bottom of the page using a simple CSS code snippet.
In this tutorial I will teach you how to add a polaroid photo effect to the Squarespace Instagram block.
In this tutorial I will teach you how to change images on hover in Squarespace Fluid Engine and 7.1 using a very simple CSS code.
In this article I will guide you through the process of implementing the Ken Burns effect on your Squarespace images, galleries, and section banners using CSS.
When a member logs into their Member Area account, the page simply refreshes and the user panel opens. This can be confusing and not the best user experience. In today's article, I'll show you how to solve this problem by sharing a simple code snippet that you can add to your website
In today's digital landscape, websites must be designed with responsiveness in mind. As a Squarespace designer, one of the most important steps in my web design process is ensuring my websites are responsive and look amazing on all displays, be it mobile, tablet, or desktop.
If you’re a business owner or a freelancer, you know that it can be stressful enough having an unstable and variable income. The last thing you want to worry about is clients that ghost you after your work is done. Your livelihood depends entirely on invoices paid on time by your clients. Unfortunately, that doesn’t always happen. Since starting my web design business, I have not encountered this problem once. Here are some tips to prevent late and non-payments
If you're a fan of Squarespace like I am, you'll know that 2022 was a banner year for the platform. They completely revamped their website builder with the "Fluid Engine" layout editor and let me tell you - it was a game changer. Building websites on Squarespace just got a whole lot easier and more stylish. But that's not all - they also rolled out a ton of new features that made it possible to create professional-grade websites without any coding skills. These updates were a total dream for anyone who loves to tinker with their website and try out the latest design trends. In this article, I'll be sharing all the details about these new features and giving you my honest thoughts on them.
Adding floating social icons that are always visible to your website is an easy way to encourage visitors to follow you on your chosen platforms and stay up to date with your content. Not only do these icons provide an easy way for visitors to connect with you, but they also contribute to the professional and cohesive look of your site. The new Fluid Engine update to Squarespace means the codes we used on 7.1 to achieve this are no longer viable and they need some tweaking.
In the web design business, like any tech-related business, technologies and trends move & change at an impossibly rapid rate. You’ve probably noticed many of these trends emerging already. If not, you’re going to notice them after reading this article.
Squarespace has just released a new feature that I've been wanting for a while: Saved Sections. In this post, I'll give you an overview of what Saved Sections are, how to use them, and how they can improve your Squarespace workflow.
In this article, I’ll show you how to create an anchor link sidebar navigation in Squarespace 7.1 and Fluid Engine.
In this article, I’ll show you how you can force the mobile navigation to show all the time, even when viewing on desktop browsers in Squarespace 7.1.
Like many, I left high-school with the task (read: burden) of deciding, that very minute, what it was that I was going to do for the rest of my life to make some semblance of a living in this tremendously costly city I call home. What do I want to be when I grow up? In western society, what that really means is: Which profession will define me a person, and how many expensive and unnecessary things do I want to buy to impress people I don’t like?
The Brine family of templates in Squarespace 7.0 offered a lovely, optional parallax feature that could be applied to banner images. 7.1 does not currently offer this option. However, with a little bit of code, we can add a (more flexible) version of the parallax effect to banner images in this updated design system.
Logos are essential for the branding of your company, and can also have an effect on the overall design of your site. This can certainly be an intimidating process if you have never designed a logo before, but it doesn’t have to be.
A complete guide to Squarespace’s 2025 pricing—Basic, Core, Plus, and Advanced. Use our free plan selector to quickly find the perfect tier for your site.