Learn Bubble with 500+ tutorials, courses & AI Assistant ✨

Limited time launch offer get $80 off today

0 days 0 hours 0 minutes 0 seconds
SAVE $80 NOW
Planet No Code logo
Bubble.io CoachingFounder MentoringSponsorships
LoginLearn Bubble.io

Should I use margins or padding?

Should I use margins or should I use padding? In this Bubble tutorial, I'm going to give a few examples because this is a common theme that I see in the Bubble coaching that we run at Planet No Code, where we do one to one sessions helping Bubble creators just like yourself, develop and overcome issues that they've got with their Bubble apps. And we experience this quite a lot with, I say, clunky layouts.

Join now $19/monthLearn more
Get 500+ tutorials, a No-Code AI Assistant, 4 premium courses, and everything you need to build faster!
Should I use margins or padding?
Explore these topics...
Design

With just this tutorial learn...

Margins vs Padding: Discover the secret to responsive layouts in Bubble!

Clunky Layouts, Begone: Learn how to create smooth, professional designs with this simple trick.

Master Container Layouts: Unlock the power of columns and rows for flawless UI design in your Bubble app.

With membership you'll...

Learn how to build a ChatGPT Clone, Custom CRM for your business & SaaS Marketing website with Webflow & AI.

Unlock 500+ Bubble tutorial videos with AI powered Q&A.

Debug your Bubble app instantly with our custom trained No Code AI Assistant.

Join now $19/month
Risk-free! 14-day money-back guarantee. Cancel anytime.

Understanding Margins and Padding in Bubble

Should I use margins or should I use padding? In this Bubble tutorial, I'm going to give a few examples because this is a common theme that I see in the Bubble coaching that we run at Planet No Code, where we do one-to-one sessions helping Bubble creators just like yourself develop and overcome issues that they've got with their Bubble apps. We experience this quite a lot with, I say clunky layouts.

Setting Up the Page Layout

I've got a page here and the container layout is column. Remember, my principle, 90, 95 percent of the time, you should be using columns and rows. If you're using fixed layouts, you're creating a huge headache for yourself if you need your app to be responsive on different screen sizes. My page is set as a column and inside that, I've got another group, I've given it a red border so it stands out, and I also have this as a column.

Using Margins for Spacing

A good instance of where I might want to use a margin would be to say that I want my red group, red border group to be 20 pixels from the top. I add in 20 pixels there, let's preview it. You can see that I've now got 20 pixel gap from the top.

The Key Difference Between Margins and Padding

The key difference, but it has a roll-on effect to how you arrange the elements on your page, is that margins apply to the outside of an element and padding applies to the inside.

Using Padding for Internal Spacing

Let's put a group inside of my red-boarded group. I'm going to give this a background color so that it's very clear. I'll go green so it stands out. Let's say that I want my green to occupy the whole width of my red-boarded group. I go into layout, change the green groups, layouts to row for example, that gives me all of these extra options. Then I just set this to 100 percent, because I want to always to take up the full width of the red-boarded group.

Common Mistakes with Margins and Padding

Now, what if I wanted to actually have a gap between the red border and the green on the left-hand side? This is where I've seen a lot of people doing it. It's very apparent when you see me do it because I've got the contrasting colors of red and green. But let me show you. If I go onto my red group, no, green group. I think, right, yeah, I want let's say 40 pixels in from the left-hand side. So I add in 40. Then if I preview that.

Invitation to Explore More Content

Hey guys, if you're finding this YouTube tutorials helpful, we invite you to explore even more content on our website at planetnocode.com. We have a large selection and variety of super in-depth and detailed video lessons created and curated just for our pain members. It's all about learning together and accelerating your no-code journey. Check us out at www.planetnocode.com and let's continue building without limits.

Understanding Overflow Issues

You'll see I get an overshoot on the right-hand side. Interestingly, oh, it does. I was about to say it doesn't show in the editor, but it does show. I overflow, is the CSS term, onto the right-hand side. That's because my green group is always going to have its width set to 100% of the width of my red one.

Correct Way to Apply Spacing

Like I said, it's very apparent when I use colors like this. But you won't believe the number of coaching apps that I've helped people on, that I've worked with, where they've got this overflow and they just not realized that it's there and it's causing all sorts of UI elements issues with how they're trying to lay out their page. So the correct way to do this is not to apply a margin to the child element. So I'm going to get rid of the left-hand margin there. But it's to apply a padding to the parent element.

Applying Padding to Parent Elements

So I can say 40% there. And okay, I'm not getting the overflow and I could even put 40% on the 40%, 40 pixels on the right-hand side. Let's preview that. So even though I've set this to 100%, it's really 100% of the usable space because the padding of the red-boarded group and then 100% and then the padding there. And so there I'm not getting an overflow.

Best Practices for Building Responsive Apps

So there's just a couple of ways and I think it's very easy mistake to make. You end up with the overflow, especially when you're using 100% width. But this is how I would go about building up my app, even if I'm building primarily for desktop. If I want it to work well, or I think maybe in the future I want to add in tablet or mobile, then I will build it using the principles that I've laid out in this video so that I don't just cause a massive headache for me later on.

Key Takeaways

So remember, margin's on the outside, padding's on the inside.

Table of contents

Heading 2
Heading 3
Heading 4
Heading 5
Heading 6
Your No-Code Journey Starts Here

The best way to learn Bubble.io?

Build No Code Confidently

No more delays. With 30+ hours of expert content, you’ll have the insights needed to build effectively.

Find every solution in one place

No more searching across platforms for tutorials. Our bundle has everything you need, with 500+ videos covering every feature and technique.

Dive deep into every detail

Get beyond the basics with comprehensive, in-depth courses & no code tutorials that empower you to create a feature-rich, professional app.

Monthly
Yearly
Member
Accelerate your Bubble app to launch
$99 / month
$19/month/mo
Includes:
500+ tutorials
4 premium courses
Find the right tutorial with our custom trained AI
New tutorials added each week
Cancel anytime
14 day money back
Join now
Member
Accelerate your Bubble app to launch
$990 / year
$149/year/mo
Includes:
500+ tutorials
4 premium courses
Find the right tutorial with our custom trained AI
New tutorials added each week
Cancel anytime
14 day money back
Join now

Frequently Asked Questions

Find answers to common questions about our courses, tutorials & content.

Do I need any coding experience?

No. Our Beginner Essentials course and AI No-Code Coach are designed for total newcomers. You’ll learn Bubble.io step by step - no coding required.

How does the AI No-Code Coach work?

Simply type your question in plain English, and our AI taps into the entire video library to recommend the exact lessons you need. It’s like having a personal instructor on demand.

How long can I access the content?

As long as you’re subscribed! With our monthly subscription, you get unlimited access to all 500+ videos, our growing course library, and the AI No-Code Coach.

What courses are included

Your subscription includes:

  • Bubble Beginner Essentials – Get up and running fast.
  • Build a ChatGPT Clone – Integrate AI into your no-code apps.
  • Build Your SaaS Website with AI – Learn to create a scalable startup site.
  • Develop a Custom CRM App in Bubble - Learn database relationships with a CRM.

Plus, new tutorials every week!

What if I get stuck on a lesson?

The AI No-Code Coach is your first stop for instant answers. If you need deeper help, you can book 1:1 Bubble coaching for expert guidance.

Do you offer a money-back guarantee?

Yes! If you don’t see real progress within 14 days, let us know, and we’ll issue a full refund—no questions asked.

Can I cancel anytime?

Absolutely. Your subscription is month-to-month, and you can cancel anytime—no lock-ins, no hidden fees.

What if I want more than just tutorials & courses?

Absolutely. Your subscription is month-to-month, and you can cancel anytime—no lock-ins, no hidden fees.

If you’re serious about building a successful SaaS startup, check out Mastery—our intensive mentorship program. Mastery goes beyond Bubble.io development and includes:

  1. 1:1 mentorship to fast-track your progress
  2. Marketing strategies tailored for no-code founders‍
  3. Product management insights to scale your startup‍
  4. Personalized support from experienced founders

‍

Still have questions?

Reach out to our dedicated team.

Contact
Services
Search Bubble TutorialsBubble.io CoursesBook Bubble.io CoachingApply for Mastery
Latest Bubble tutorials
Rerank Text By MEANING With Cohere In Bubble.io Step by Step!
Unlock RAG Providers for NO CODE AI App Development TODAY!
Better Tables with Built-in Search and Sort By in Bubble.io
Partnerships
Flusk.eu
VectorShift
Comnoco
Plumb
Toddle
Whereby
Get started with no code
AI Powered No Code AppsNo Code Web ScrapingBubble.io Plugin tutorialsBubble API Connector tutorialsStudent & Teacher DiscountBest tools for no coders
Follow us
Youtube
X
LinkedIn
Planet No Code logo
In partnership with
Queen Mary University of London Logo
© 2024 Planet No Code. All rights reserved.
Privacy PolicyTerms of ServiceCookies SettingsContact Us