DEV Community

Cover image for Make Your Terminal Beautiful with Python: ASCII Art & Fancy Progress Bars ✨🐍!!
Nishkarsh Pandey
Nishkarsh Pandey

Posted on

Make Your Terminal Beautiful with Python: ASCII Art & Fancy Progress Bars ✨🐍!!

Want to level up your terminal output with cool animations, progress bars, and fancy ASCII art? This quick guide shows you how to combine three awesome Python libraries to do just that:

pyfiglet β€” for eye-catching ASCII text banners.
tqdm β€” for simple, elegant progress bars.
rich β€” for colorful, animated progress bars and spinners.

Why Care About Terminal Styling?

When building CLI tools or scripts, output styling helps:
Make the experience more engaging.
Provide clear feedback on progress.
Impress your friends πŸ˜„.

Code Example
Here’s a concise Python script that shows off each library’s strength:

import pyfiglet
from tqdm import tqdm
from rich.console import Console
from rich.progress import track
import time

# ---------- 1. ASCII Art ----------
ascii_banner = pyfiglet.figlet_format("Nishkarsh!")
print(ascii_banner)

# ---------- 2. TQDM Progress Bar ----------
print("\n[1] Loading with tqdm:")
for _ in tqdm(range(50), desc="Loading..."):
    time.sleep(0.02)

# ---------- 3. Rich Progress Bar ----------
console = Console()
print("\n[2] Fancy Progress with Rich:")
for step in track(range(10), description="Processing tasks..."):
    time.sleep(0.1)

# ---------- 4. Rich Spinner / Status ----------
print("\n[3] Animated Spinner with Rich:")
with console.status("[bold green]Finalizing magic..."):
    time.sleep(2)

console.print("\n[bold cyan]All done! Your terminal is now beautiful. 🌈[/bold cyan]")

Enter fullscreen mode Exit fullscreen mode

Output:

Terminal

What Happens Here?
pyfiglet creates a big ASCII banner for the text "Nishkarsh!" β€” perfect for logos or script headers.

tqdm shows a simple progress bar with a label "Loading..." that fills up as the loop runs.

rich’s track() gives a colorful, animated progress bar with the label "Processing tasks...".

rich also lets you create a spinner with a status message (Finalizing magic...) to show a task in progress.

Finally, it prints a colored success message with emoji to celebrate!

How to Run This
Install dependencies:

pip install pyfiglet tqdm rich

Enter fullscreen mode Exit fullscreen mode

Save the script as terminal_magic.py
Run:

python terminal_magic.py

Enter fullscreen mode Exit fullscreen mode

What Else Can You Do?

Combine rich’s tables, trees, and markdown for killer CLI apps.
Use pyfiglet for dynamic banners in your CLI projects.
Customize tqdm with colors, nested bars, and more.

Final Thoughts
Adding some style to your terminal output is easier than you think β€” and it makes your tools so much nicer to use. Give these libraries a try and watch your command line come alive!

Top comments (21)

Collapse
 
melody_kelly_n profile image
Melody Kelly. N

Looks good 🀝🎯

Collapse
 
nish2005karsh profile image
Nishkarsh Pandey

Thanks a ton, Melody! Really appreciate the support πŸ€πŸ˜„ More terminal fun on the way! πŸš€πŸ–₯️

Collapse
 
melody_kelly_n profile image
Melody Kelly. N

Really appreciate it. Thanks

Thread Thread
 
nish2005karsh profile image
Nishkarsh Pandey

Thanks so much, Melody! I really appreciate your support and enthusiasm. Looking forward to sharing more fun terminal projects together! πŸ™ŒπŸβœ¨

Collapse
 
nadeem_zia_257af7e986ffc6 profile image
nadeem zia

Interesting to read

Collapse
 
nish2005karsh profile image
Nishkarsh Pandey

Thanks Nadeem 😊

Collapse
 
cua57 profile image
Pelo

That’s a great summary! You’ve highlighted some awesome ways to level up CLI apps with style and interactivity.

Collapse
 
nish2005karsh profile image
Nishkarsh Pandey

Thanks so much, Pelo! Glad you liked the summary β€” making CLI apps both powerful and visually appealing is definitely a game changer!

Collapse
 
samuraix13 profile image
SamuraiX[13~]

I knew about Rich but never saw tqdm, look really nice! thank you for showing the picture of them as well

Collapse
 
nish2005karsh profile image
Nishkarsh Pandey

Thanks a lot, SamuraiX! 😊
Yeah, tqdm is such a hidden gem β€” pairs beautifully with rich for that aesthetic + functional combo. Glad the visuals helped! Let me know if you try something cool with them !!

Collapse
 
samuraix13 profile image
SamuraiX[13~]

Oh sure would love to! but unfortunately SAT exam is getting too much close to me lol, I have less than 2 weeks till exam, would gladly write any project just for the sake of programming after my exam as I really miss programming

Thread Thread
 
nish2005karsh profile image
Nishkarsh Pandey

Totally get that, SamuraiX! Best of luck crushing your SAT β€” programming projects will be waiting for you after, and they’ll be even more fun with a fresh mind. You've got this! πŸ’ͺ
By the way, what colleges are you aiming for or hoping to get into?

Collapse
 
dotallio profile image
Dotallio

Love this! Using rich and tqdm honestly makes any CLI so much more fun to work with. Have you tried combining rich’s tables with pyfiglet headers for full-on dashboards?

Collapse
 
nish2005karsh profile image
Nishkarsh Pandey

Thanks so much! πŸ™Œ I totally agree β€” rich and tqdm can really bring a CLI to life!
And yes β€” using pyfiglet headers with rich tables is such a power combo! 🎨 It gives off those retro looking dashboard vibes in the terminal πŸ˜„
I’ve been experimenting a bit with that setup actually β€” like displaying a pyfiglet banner as the section title, followed by a well-styled rich.table for stats or task lists. It's surprisingly satisfying to look at!
Might even turn it into a mini dashboard project next. Have you built anything like that yet?

Collapse
 
aiquant_labs profile image
AIQuant Labs

Good job!

Collapse
 
nish2005karsh profile image
Nishkarsh Pandey

Thank you so much! Glad you liked it β€” more Python terminal magic coming soon! πŸ”₯🐍

Collapse
 
aiquant_labs profile image
AIQuant Labs

Its Awesome

Collapse
 
nish2005karsh profile image
Nishkarsh Pandey

Thanks !!!

Collapse
 
nathan_tarbert profile image
Nathan Tarbert

pretty cool, i always tweak my scripts with stuff like this - you think nice visuals actually help you stay motivated during long runs or is it just for fun?

Collapse
 
nish2005karsh profile image
Nishkarsh Pandey

Thanks! Honestly, a bit of both. I’ve noticed that having fun visuals like ASCII art or animated progress bars makes long-running scripts feel more engaging. It’s like adding a little personality to the terminal. Sometimes it’s just aesthetic, but other times it genuinely helps break the monotony and keep me focused. Glad to hear you tweak your scripts too β€” it’s underrated fun!

Collapse
 
melody_kelly_n profile image
Melody Kelly. N

Cool