std::format and Custom Types (a 1500 word - exclusive article)


Today I'm happy to present a new bonus article about std::format and custom types.

You can find an introduction to std::format in a guest post at C++ Stories:

But how about formatting custom types?

For streams, you could just override operator<<, is this also simple for std::format?

See in the attached pdf article: format_custom_types.pdf

The article comes from a recent discussion at our Discord Server. The topic was so interesting that I tried to understand the details and wrote the article.

Attached there are also recent pdfs of the blog posts.

Best regards


Become a patron to

Unlock 271 exclusive posts
Be part of the community
Get discounts to an online store
Connect via private message
$3 per month

At this level you can stay up to date with the latest C++ news and C++ Stories. Here's what you'll get:
  • Access to my feed with weekly updates
  • Curated News and Article Descriptions
  • Access to exclusive Discord Server
  • My Book: C++ Lambda Story for free, see at
Includes Discord benefits
Know & Learn since 2022
$6 per month

It looks like you want to get even more C++ content!
At this level you'll get everything from the "Up-to-date!" plan, plus:

  • Data Member initialization Book for free
  • Extended or exclusive articles (usually twice per month)
  • Extended C++20 ref Card
  • Early access to new blog posts
  • Access to all content from previous years
  • Additional Product Promotions
  • PDF version of recent blog posts
Stay at the Edge
$15 per month
You rock!

You'll get everything for the previous plan plus:

  • Free version of my C++17 in Detail book,
  • *OR* Free Print Version of Lambda Story (if reachable from
  • Huge discounts for future projects (or even free access)
Includes Discord benefits
Recent Posts