Title: zlib Compression &amp; Updates
Last modified: March 1, 2019

---

# zlib Compression & Updates

 *  [mtharani](https://wordpress.org/support/users/mtharani/)
 * (@mtharani)
 * [7 years, 2 months ago](https://wordpress.org/support/topic/zlib-compression-updates/)
 * I’m trying to understand a “bug” that’s causing my some grief and why it exists.
   Essentially, we have enabled zlib compression on a dedicated server running Apache.
   As a result, when updating plugins/themes, it doesn’t complete properly in the
   UI while continuing in the background. A bug was opened 7 years ago and then 
   re-opened 7 days ago. The only “solution” provided just hides the error from 
   the logs. Alternatively, turning off zlib compression fixes the issue. We’ve 
   discussed this issue with our hosting provider and with cPanel and both are blaming
   this on WordPress. I’m stuck in the middle. I like zlib compression, so I don’t
   want to turn it off, but we’ve come across a few plugins that don’t re-activate
   because of this and that’s not good. Any help would be appreciated.
 * Bug
    [https://core.trac.wordpress.org/ticket/18525](https://core.trac.wordpress.org/ticket/18525)
 * Similar Post
    [https://wordpress.org/support/topic/dashboard-update-process-does-not-complete/](https://wordpress.org/support/topic/dashboard-update-process-does-not-complete/)

Viewing 1 replies (of 1 total)

 *  [Dion](https://wordpress.org/support/users/diondesigns/)
 * (@diondesigns)
 * [7 years, 2 months ago](https://wordpress.org/support/topic/zlib-compression-updates/#post-11265343)
 * `zlib.output_compression` should always be turned off in PHP because it conflicts
   with output buffering.
 * If you want output compression, you should instead turn it on in Apache, where
   you have a choice of gzip or (if your server supports it) brotli compression.
   It should only be enabled for specific types of content, for example:
 *     ```
       <FilesMatch "\.(js|css|svg|html|htm|xml|json|php)$">
       	SetOutputFilter DEFLATE
       </FilesMatch>
       ```
   
 * The above would enable gzip compression when serving files with specific extensions.
   It can be added to a .htaccess file, but since you said you have a dedicated 
   server, it would be better to set this in the global httpd.conf file.

Viewing 1 replies (of 1 total)

The topic ‘zlib Compression & Updates’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 1 reply
 * 2 participants
 * Last reply from: [Dion](https://wordpress.org/support/users/diondesigns/)
 * Last activity: [7 years, 2 months ago](https://wordpress.org/support/topic/zlib-compression-updates/#post-11265343)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
