<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/new-in-symfony-8-2-more-flexible-serialization-groups-symfony-blog--s7l6m91ib" -->

---
title: New in Symfony 8.2: More Flexible Serialization Groups...
description: Symfony 8.2 expands serialization group configuration with repeatable, group-scoped #[SerializedName] and #[SerializedPath] attributes, letting the same...
canonical: https://daily.dev/posts/new-in-symfony-8-2-more-flexible-serialization-groups-symfony-blog--s7l6m91ib
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: New in Symfony 8.2: More Flexible Serialization Groups (Symfony Blog) | daily.dev
og:description: Symfony 8.2 expands serialization group configuration with repeatable, group-scoped #[SerializedName] and #[SerializedPath] attributes, letting the same...
og:url: https://daily.dev/posts/new-in-symfony-8-2-more-flexible-serialization-groups-symfony-blog--s7l6m91ib
og:image: https://api.daily.dev/og/posts/s7L6m91ib.png
og:image:alt: New in Symfony 8.2: More Flexible Serialization Groups (Symfony Blog)
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# New in Symfony 8.2: More Flexible Serialization Groups (Symfony Blog)

**[Symfony](https://daily.dev/sources/symfony)** · 4 min read · 2 upvotes · 0 comments

## Summary

Symfony 8.2 expands serialization group configuration with repeatable, group-scoped #[SerializedName] and #[SerializedPath] attributes, letting the same property use different keys per API version. A new ignored_groups context option excludes properties by group, and an enable_default_groups option mimics the Validator component's Default/class-name group convention in the Serializer. Controllers and Messenger can now use named serializers independently, so changing an API's serializer settings no longer affects Messenger message formatting.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://symfony.com/blog/new-in-symfony-8-2-more-flexible-serialization-groups>

## Questions this post answers

### How do I use different serialized property names for different API versions in Symfony 8.2?

Symfony 8.2 makes the #[SerializedName] and #[SerializedPath] attributes repeatable and accepts a groups argument, so the same property can map to different keys depending on the active serialization group. For example, a property can serialize as product_name under an api_v1 group and as name under api_v2, with a name defined without groups acting as a fallback.

_Teams versioning APIs in Symfony can track serializer changes like this on daily.dev._

### How do I exclude properties by serialization group instead of always ignoring them in Symfony?

Symfony 8.2 adds the AbstractNormalizer::IGNORED_GROUPS context option (ignored_groups), which excludes properties belonging to specified groups only in that serialization context, unlike the #[Ignore] attribute which always excludes a property. Context builders can call the new withIgnoredGroups() method to achieve the same result.

_Developers fine-tuning Symfony serialization behavior can follow updates like this via daily.dev._

### Can Symfony Messenger use a different serializer than my API controllers?

Yes, in Symfony 8.2 controllers and Messenger can each use independently configured named serializers. Previously #[MapRequestPayload], #[MapQueryString], #[Serialize], and Messenger's symfony_serializer transport all shared the default serializer service, so changing API serializer settings could unintentionally alter Messenger message formatting.

_Engineers separating API and messaging concerns in Symfony can keep up with such changes on daily.dev._

## Similar posts on daily.dev

- [Symfony 8.1 curated new features \(Symfony Blog\)](https://daily.dev/posts/symfony-8-1-curated-new-features-symfony-blog--9qonflcdy) · Symfony · 4 upvotes · 0 comments
- [New in Symfony 8.1: Messenger Improvements \(Symfony Blog\)](https://daily.dev/posts/new-in-symfony-8-1-messenger-improvements-symfony-blog--ofndylze4) · Symfony · 4 upvotes · 0 comments
- [New in Symfony 8.1: Improved JSON Streaming and Querying \(Symfony Blog\)](https://daily.dev/posts/new-in-symfony-8-1-improved-json-streaming-and-querying-symfony-blog--doadnpbjr) · Symfony · 4 upvotes · 0 comments
- [Symfony 8.1.1 released \(Symfony Blog\)](https://daily.dev/posts/symfony-8-1-1-released-symfony-blog--ocbnpt8kl) · Symfony · 7 upvotes · 0 comments
- [New in Symfony 8.1: DX Improvements \(Part 1\) \(Symfony Blog\)](https://daily.dev/posts/new-in-symfony-8-1-dx-improvements-part-1-symfony-blog--sito6mhet) · Symfony · 1 upvotes · 0 comments

---

Tags: [#architecture](https://daily.dev/tags/architecture), [#php](https://daily.dev/tags/php), [#symfony](https://daily.dev/tags/symfony)

[View this post on daily.dev](https://daily.dev/posts/new-in-symfony-8-2-more-flexible-serialization-groups-symfony-blog--s7l6m91ib)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"New in Symfony 8.2: More Flexible Serialization Groups (Symfony Blog)","url":"https://daily.dev/posts/new-in-symfony-8-2-more-flexible-serialization-groups-symfony-blog--s7l6m91ib","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/new-in-symfony-8-2-more-flexible-serialization-groups-symfony-blog--s7l6m91ib"},"datePublished":"2026-10-01T08:44:44.444Z","dateModified":"2026-10-01T08:45:06.078Z","description":"Symfony 8.2 expands serialization group configuration with repeatable, group-scoped #[SerializedName] and #[SerializedPath] attributes, letting the same...","image":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/327b244859fddae8f3a20d0225898aa0?_a=AQAEuop","thumbnailUrl":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/327b244859fddae8f3a20d0225898aa0?_a=AQAEuop","isAccessibleForFree":true,"articleSection":"Symfony","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"Symfony","logo":"https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/cc07051b7112472f9729e73c14660a64","url":"https://daily.dev/sources/symfony"},"commentCount":0,"discussionUrl":"https://daily.dev/posts/new-in-symfony-8-2-more-flexible-serialization-groups-symfony-blog--s7l6m91ib","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":2},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"keywords":"architecture,php,symfony","timeRequired":"PT4M"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"Symfony","item":"https://daily.dev/sources/symfony"},{"@type":"ListItem","position":3,"name":"New in Symfony 8.2: More Flexible Serialization Groups (Symfony Blog)"}]}
{"@context":"https://schema.org","@type":"FAQPage","@id":"https://daily.dev/posts/new-in-symfony-8-2-more-flexible-serialization-groups-symfony-blog--s7l6m91ib#faq","mainEntity":[{"@type":"Question","name":"How do I use different serialized property names for different API versions in Symfony 8.2?","acceptedAnswer":{"@type":"Answer","text":"Symfony 8.2 makes the #[SerializedName] and #[SerializedPath] attributes repeatable and accepts a groups argument, so the same property can map to different keys depending on the active serialization group. For example, a property can serialize as product_name under an api_v1 group and as name under api_v2, with a name defined without groups acting as a fallback. Teams versioning APIs in Symfony can track serializer changes like this on daily.dev."}},{"@type":"Question","name":"How do I exclude properties by serialization group instead of always ignoring them in Symfony?","acceptedAnswer":{"@type":"Answer","text":"Symfony 8.2 adds the AbstractNormalizer::IGNORED_GROUPS context option (ignored_groups), which excludes properties belonging to specified groups only in that serialization context, unlike the #[Ignore] attribute which always excludes a property. Context builders can call the new withIgnoredGroups() method to achieve the same result. Developers fine-tuning Symfony serialization behavior can follow updates like this via daily.dev."}},{"@type":"Question","name":"Can Symfony Messenger use a different serializer than my API controllers?","acceptedAnswer":{"@type":"Answer","text":"Yes, in Symfony 8.2 controllers and Messenger can each use independently configured named serializers. Previously #[MapRequestPayload], #[MapQueryString], #[Serialize], and Messenger's symfony_serializer transport all shared the default serializer service, so changing API serializer settings could unintentionally alter Messenger message formatting. Engineers separating API and messaging concerns in Symfony can keep up with such changes on daily.dev."}}]}
```

