Latest News

This is the official Slim Framework blog where you'll find release announcements and community news.

Subscribe with RSS

Slim 4.14.0 released

We are pleased to have released Slim 4.14.0. As a mature release, there aren’t many changes and all are minor and can be seen here.

Slim 3.12.2 released

This is the last release for Slim 3. Minor bug fixes and improvements.

Slim 3.12.0 released

It’s a new year, so a new Slim! Like 3.11.0, version 3.12.0 is nearly entirely bug fixes.

Slim 3.11.0 released

With the end of summer, we are delighted to release Slim 3.11.0. This version is pretty much entirely bug fixes.

Slim 3.10.0 released

We are delighted to release Slim 3.10.0. This version has a couple of minor new features and a couple of bug fixes.

Slim 3.9.0 released

We are delighted to release Slim 3.9.0. As Slim 3 is stable, there’s mostly bug fixes in this version.

Slim 3.8.0 released

It’s been a few months since the last release, so Slim 3.8.0 has a few more things in it. This version updates Slim to be compatible with PSR-11 containers so that you can now use a PSR-11 container with it.

Slim 3.7.0 released

Slim 3.7.0 is a small release containing a one bug fixes and a new feature: we now pass the Exception into the NotFoundHandler so that custom handlers have access to this additional information. If you work with cookies, then you’ll be glad to know that we have fixed a bug in our cookie parser so that commas are handled properly!

Slim 3.6.0 released

Slim 3.6.0 is a small release containing a few bug fixes and a new method. A particularly useful bug fix is that the Response’s withJson() method now correctly removes any data currently in the body before inserting its own data. We also have a new convenience method on Request: getServerParam() allows access to a single parameter from $_SERVER.

Slim 3.5.0 released

A few useful bug fixes in this release including the ability to read the ‘Authorization’ header without tweaking .htaccess files or manually looking in getallheaders()!

Slim 3.4.2 released

3.4.1 had a BC break when handling errors where the acceptable media type listed in the Accept header wasn’t the first one. This is now fixed.

Slim 3.4.1 released

This releases fixes a infinite loop bug discovered in version 3.4.0 and also adds additional unit tests.

Slim 3.4.0 released

This release add a number of new features and improvements. Firstly, we now support media type structured suffixes (+json & +xml) for our Request’s body parser and error response output. Routing has also seen some improvements with two new methods: removeNamedRoute() and setPattern() and you can now cache the parsed FastRoute route information to a cache file with the routerCacheFile setting.

Slim 3.3.0 released

This release tidies up a few issues found in our PSR-7 implementation around the Request’s body and uploaded files. In particular, we now handle file input elements with names containing nested arrays correctly.

Slim 3.2.1 released

Shortly after releasing version 3.2.0, we discovered that we had inadvertently made life very difficult for people who write their own invocation strategies as it was now impossible to inspect the actual callable passed to the strategy. Obviously we don’t like to break people’s working applications, so version 3.2.1 resolves this issue (#1785).

Slim 3.2.0 released!

We have released Slim version 3.2.0. There are not that many changes since 3.1.0, but we found a few bugs to fix and have added a few nice improvements, particularly around error handling.

Slim 3.1.0 released!

We have released Slim version 3.1.0. This version makes a number of minor issues and improvements since the release of 3.0.0

Slim 3.0.0 released!

We are delighted to release the first stable version of Slim 3, 3.0.0 following a series of release candidates.

Slim 3 Beta 1

We have tagged beta 1 of Slim 3 and have started the journey of releasing the first stable version of 3.0. We have also started work on the new documentation.

Treehouse Slim Framework Tutorials

Treehouse and Hampton Paulk have published a new tutorial series that demonstrates how to create a website with the Slim Framework. It’s aimed at PHP beginners, and it teaches you how to use Composer, Slim, SwiftMailer, and Monolog while building a simple website.


Lumen happened. It’s a shiny new micro-framework from Taylor Otwell, and it joins the Laravel family today. It looks to be a pretty nice framework, and it shares many of the same features and goals as Slim 3.0. I’m sure this raises a few question about Slim’s future roadmap.

Version 2.6.0

We’ve just released version 2.6.0. This update includes a small but important fix for a potential object injection vulnerability in the SessionCookie class. We encourage you to update your applications as soon as possible. This update also includes several other improvements. You can read more on the GitHub release page.

Slim Framework GitHub Organization

The Slim Framework code repositories have a new home in their very own GitHub Organization. As much as I’d like to keep the project beneath my own GitHub handle for the notoriety and what not, the project is best served with its own GitHub Organization. This solves several problems.

What's up with version 3.0?

It’s coming. I promise. As many of you know, I recently finished writing a new book for O’Reilly Media—Modern PHP. I’m excited that my book is nearing publication and should be on bookshelves within a month or two. Unfortunately, writing a book is a time-consuming task. I also have a 9 to 5 day job. Life gets in the way sometimes. Excuses, excuses… I know :) I now have free time to work on Slim again. So what’s going on? A lot.

Slim Framework Version 2.3.0

The Slim Framework contains many new and helpful features in version 2.3.0. It is backwards compatible with the previous version. While I update the official documentation, here are some tips to help you get started with Slim’s new features.

Cookie handling updates

The next major point release to the Slim Framework will simplify how you get and set encrypted cookies. Previously, you would use the Slim application’s getEncryptedCookie() and setEncryptedCookie() methods to get or set an encrypted cookie.

Upcoming changes to the Slim Framework

Now that the day job is finally slowing down a bit, I’ve been back at work on the Slim Framework. Here are several new features and changes coming in the next stable release — currently available in the develop branch to help you start updating your applications.

Slim Framework 2

I recently released Slim Framework 2. This is a radical departure from past versions. Version 2 introduces PSR-2 compliance and PHP namespaces. It requires PHP 5.3 or newer.

Moving Forward

The next version of the Slim Framework will introduce PHP namespaces and PSR-2 compliance. Because this is a large departure from the past, I will tag this version “2.0” when it is released (soon).

Slim Framework Version 1.6.7

I’ve just released Slim Framework 1.6.7. This minor release is recommended for everyone and includes the following changes:

Slim Framework Version 1.6.6

I’ve just released Slim Framework 1.6.6. This minor release is recommended for everyone and includes the following changes:

Slim Framework Version 1.6.5

I’ve just released Slim Framework 1.6.5. This minor release is recommended for everyone and includes the following changes:

Launch apps on PagodaBox with the Slim Framework Quickstart

Now you can instantly launch new Slim Framework applications on PagodaBox with the official Slim Framework quickstart. You don’t have to worry about creating filesystem directories, downloading and installing the Slim Framework libraries, or messing with complicated deployment routines.

Slim Framework Version 1.6.4

I’ve just released Slim Framework 1.6.4. This minor release is recommended for everyone and includes the following changes:

Slim Framework Version 1.6.3

I’ve just released Slim Framework 1.6.3. This minor release is recommended for everyone and includes the following changes:

Slim Framework Version 1.6.2

I’ve just released Slim Framework 1.6.2. This minor release fixes a bug with Flash messaging when used with the session cookie middleware. I strongly encourage you to upgrade your Slim 1.6.x applications to this version.

Use Slim Framework with Composer and Packagist

I’m happy to announce that the Slim Framework now works with Composer and is available on Packagist. Andrew Smith at Silent Works has written a tutorial that demonstrates how to use Composer and Packagist to manage dependencies in your Slim application.

Slim Framework Version 1.6.1

I’ve just released Slim Framework 1.6.1 into the stable branch. This release includes several bug fixes and general improvements to the recent 1.6.0 release. Changes in this version include:

Slim Framework Version 1.6.0

I’ve just released Slim Framework 1.6.0 into the stable branch. This is a major release and includes a brand new framework architecture based upon the Rack Protocol.

Slim Framework Moves to Pagoda Box

The Slim Framework website is now hosted with Pagoda Box. I’m super excited about the move. If you haven’t heard already, Pagoda Box is a PHP PaaS that provides a very flexible and scalable architecture for your PHP applications.

Automatically parse an HTTP request by content type

The Slim Framework for PHP 5 version 1.6.0 (currently in the develop branch) introduces new middleware that will automatically parse the HTTP request body based on its content type. This middleware will parse HTTP requests with a JSON, XML, or CSV content type. To enable this middleware, do this:

Version Numbers

Thus far, the Slim Framework’s version numbers have mostly adhered to the major.minor.revision scheme. However, sometimes the version numbers have strayed from this practice. Slim is my first large open source project, and it is an ongoing learning experience for me as Slim’s user base continues to flourish.

Our support forum now uses Tender

I am happy to announce that Slim’s support forum and knowledge base now run on Tender™. We previously used the Vanilla forum software, but it proved unstable and unreliable for many users. I want to extend a big thank you to Tender for setting up an open source account for us. Our initial impression is that it is a phenomenal platform, and we cannot wait to put it to good use.

MultiMarkdown Community Documentation

The Slim Framework documentation has moved into the Git repository as of v1.5.2 (currently in the development branch). This change makes it easy for the community to suggest additions or changes to the framework documentation.

Version 1.5.2 has landed

The Slim Framework v1.5.2 introduces a new architecture. Several other features have changed and improved. This is a large update and is currently considered beta. Use this version at your own risk. It will remain in the develop branch until users have had sufficient time to vet the new version with their applications.

How to run a Slim app on PHPFog

Many Slim Framework users are turning to PHPFog — a leader among a growing field of PHP PaaS providers — to host their Slim Framework PHP web applications. By default, a Slim app will not run on PHPFog. Why not? PHPFog’s backend infrastructure relies on the nginx HTTP Proxy Module to communicate between backend tiers; the nginx HTTP Proxy Module speaks HTTP/1.0 while Slim speaks HTTP/1.1. Fear not, there’s an easy workaround. To run a Slim app on PHPFog, you must tell your Slim app to speak HTTP/1.0. You can do this when you instantiate your Slim app, like this:

How to organize a large Slim Framework application

The Slim Micro Framework is a micro framework that enables developers to quickly write RESTful web applications and APIs. I emphasize micro because Slim is just that — a lightweight and nimble PHP framework used to build smaller web applications and APIs. Unlike CodeIgniter and Symfony (excellent frameworks created by EllisLab and Sensio Labs, respectively), Slim forgoes controllers and abstract components for simplicity and ease-of-use.

The Slim Framework Application Lifecycle

The essence of a web application is simple: it receives an HTTP request; it invokes the appropriate code; and it returns an HTTP response. The Slim Framework makes it dead simple to build and launch small web applications and APIs by hiding the prerequisite application underpinnings beneath a simple, easy-to-use interface. But for those interested in the low-level details, here’s what a Slim application’s lifecycle looks like from start to finish.

Say Hello World with Slim

This tutorial demonstrates the typical process for writing a Slim Framework application. The Slim Framework uses the front controller pattern to send all HTTP requests through a single file — usually index.php. By default, Slim comes with a .htaccess file for use with the Apache web server. You’ll typically initialize your app, define your routes, and run your app in the ``index.php`.