# Performance regression from using \`email.message.Message.get\_params()\` as replacement of \`cgi.parse\_header\` following PEP 594

**URL:** <https://discuss.python.org/t/performance-regression-from-using-email-message-message-get-params-as-replacement-of-cgi-parse-header-following-pep-594/99963>\
**Category:** Python Help\
**Tags:** performance\
**Created:** [July 24, 2025, 1:01pm UTC](https://discuss.python.org/t/performance-regression-from-using-email-message-message-get-params-as-replacement-of-cgi-parse-header-following-pep-594/99963 "2025-07-24T13:01:51Z")\
**Posts on this page:** 1\
**Showing post:** 6

<div class="post-metadata">

**Author:** ![brettcannon](https://sea2.discourse-cdn.com/flex002/user_avatar/discuss.python.org/brettcannon/32/34895_2.png) [@brettcannon](https://discuss.python.org/u/brettcannon)\
**Post date:** [September 3, 2025, 9:07pm UTC](https://discuss.python.org/t/performance-regression-from-using-email-message-message-get-params-as-replacement-of-cgi-parse-header-following-pep-594/99963/6 "2025-09-03T21:07:10Z")

</div>

> [@nessita](#):
>
> Could you or someone else advise on next steps?

You can open an issue, but I would advise you keep your backport of `cgi.parse_header()` if it gives you the performance you’re after.

> [@nessita](#):
>
> keeping the Python stdlib offers better maintainability

I know how that might look like that from the outside, but cgi and the other modules we deprecated were due to low usage and low maintenance help (i.e. no core dev ownership).

---

_[View the full topic](https://discuss.python.org/t/performance-regression-from-using-email-message-message-get-params-as-replacement-of-cgi-parse-header-following-pep-594/99963)._
