How to count just weekdays in Bubble.io
In this Bubble tutorial, you'll learn how to exclude certain days of the week from a list of dates in your Bubble app.
Exclude weekends from your date range: Learn how to filter out Saturdays and Sundays in your Bubble date picker with this quick tutorial!
Count only weekdays in Bubble: Discover the simple trick to conditionally count just business days in your date calculations.
Master date filtering in Bubble: Unlock the power of custom date ranges and learn how to manipulate date lists like a pro.
Introducing the Video Tutorial
Have you ever wondered how you can exclude certain days of the week from a list of dates in your Bubble app? Well, I'm going to show you in this video. But before I dive into it, we've got hundreds of Bubble tutorial videos that you can't find on YouTube. You can only find them on our website planetnocode.com, so join our no-code app builder community there today.
Demonstrating the Date Picker Functionality
Let me just demo this. It's going to be really quick. I've got a date picker here. The particular date picker I'm using is by Zeroqode. It's the air date/time picker, and I've got it added to my page here. I've got just a default range, so I'm saying today's current date time and then I'm adding in 12 days. You can see that today is indeed Friday, but it skips Saturday and Sunday, then goes through the next week and then skips the following Saturday and Sunday until it arrives at that plus 12 days.
Explaining the Implementation
So let me show you how I've gone about and done this. The air date time picker version 2, which is I think the only one that's now available (that's because of the changeover the response vengeance), anyway it should look like this. You can say selected range as a list and then you can filter that list. So you can say this date, and we're talking about an individual date in the list now, and we can extract the day.
When we extract the day in Bubble, it returns like an index value of days starting from Sunday. So Sunday returns zero. That's why I'm saying not zero, and then Monday would return one, and it counts all the way through to Saturday. So Saturday is six, so that's why I've got these constraints in there.
Formatting the Output
Then I'm simply saying format in a way that I can clearly demonstrate to you the day of the week and the date. Then I'm using join with and line_break, and that has enabled me to get this list here where each item is listed on a separate line. Notice it doesn't actually print line break. That is how you use join with to achieve a line break when you're joining together a list of text items.
Counting Weekdays
I'll show you one other thing here. What if we wanted to just know how many there were? So let's add in a text label. I'm going to say the air date time picker selected range as list, and then I will do basically build up the same thing. I will filter. I'll say this date extract (easy to get these mixed up) day is going to be that 0 to 6 Sunday to Saturday. Date is going to be well, today is the 5th of January, so it will be 5. So I want day is not zero to exclude Sundays and then 6. Now I've got my list and I can then simply say count. We'll preview that.
So there's nine. One, two, three, four, five, six, seven, eight, nine. Good, I was hoping that would total up.
Conclusion and Call to Action
Anyway, that's how you go about it. If you want to see any more Bubble tips and tricks, please like and subscribe to this video. If you want to see anything else about working with dates in Bubble, please leave a comment down below. We read every single one, and we generally are trying to be as helpful as possible to the Bubble and no-code community.
Ready to Transform Your App Idea into Reality?
Access 3 courses, 400+ tutorials, and a vibrant community to support every step of your app-building journey.
Start building with total confidence
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 400+ 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.
Valued at $80
Valued at $85
Valued at $30
Valued at $110
Valued at $45
14-Day Money-Back Guarantee
We’re confident this bundle will transform your app development journey. But if you’re not satisfied within 14 days, we’ll refund your full investment—no questions asked.
Can't find what you're looking for?
Search our 300+ Bubble tutorial videos. Start learning no code today!
Frequently Asked Questions
Find answers to common questions about our courses, tutorials & content.
Not at all. Our courses are designed for beginners and guide you step-by-step in using Bubble to build powerful web apps—no coding required.
Forever. You’ll get lifetime access, so you can learn at your own pace and revisit materials anytime.
Our supportive community is here to help. Ask questions, get feedback, and learn from fellow no-coders who’ve been where you are now.
Absolutely. If you’re not satisfied within 14 days, just reach out, and we’ll issue a full refund. We stand by the value of our bundle.
Yes, this is a special limited-time offer. The regular price is $350, so take advantage of the discount while it lasts!