This blog was contributed by Drupal Association Supporting Partner, Code Enigma.
In this blog, you will learn why we, Code Enigma, use Symfony, what the framework is, and why we think it’s an excellent choice for us as a Drupal agency.

Web development is a lot like how a watch works. Each part of an application needs to function correctly and integrate perfectly to respond to what the user wants. Similarly to how the components of the watch mechanism have to move flawlessly so the second hand can continually and accurately sweep across the dial.
So, let’s talk about how that happens using Symfony.
78.8% of all websites are created using PHP (W3techs, June 2020).
A website or web app can be purely built in PHP or, at least, one of its frameworks. And this is dependent on how complex the app is or the timeframe of development. Other factors like how experienced your developers are can also come into play.
Symfony is one of the most popular frameworks available. And at Code Enigma, we touch Symfony every single day. In fact, our client dashboard was written in Symfony as well as being a significant part of our project work.
What is a Framework?
If you’re not technical, don’t worry. We’ll quickly explain what a framework is before we tell you why Symfony is excellent.
A framework is essentially a collection of universal and reusable programs. They complete specific tasks that contribute to the development of software applications.
Let’s use another metaphor.
Imagine Symfony is a blank canvas for what will become a website or web application — which is the final artwork. You need to use paint to create your artwork, a developer needs a framework in which to place modules and features. Symfony is the canvas and the modules and features are the paint.
A framework isn’t mandatory. It’s a good idea, though because it makes the process simpler and smoother. Otherwise, you’ll end up with paint all over your hands.
Here’s how using a framework makes life easier:
- Faster development - Win back up to three days of development time by repurposing out-of-the-box components. This time can be utilised for features that aren’t MVP.
- Fewer issues - Reduce the number of errors by using frameworks with exact and proven coding.
- More secure - Framework components are subjected to regular security updates.
- Efficient maintenance - Adopting a framework gives you structure basic rules to follow. A new developer could join and immediately have an idea of where to start on a project that’s already kicked off.
Is Symfony the best framework?
We won’t categorically say it’s the best. But, it has got a solid reputation as one of the most reliable, mature PHP frameworks. We’re not saying Symfony is the best for everything, because we know there is no one size fits all solution. We firmly believe in working with a client and their team to understand the business and project objectives first. This way, we can create the best solution from there using the tools we know.
Realistically, any given framework will only be as good as the developer using it. Meaning, if you have an expert developer, you can trust the solution.
Symfony is feature-rich and highly flexible. Here are a few things that make Symfony our framework of choice:
Components
Components are generic features that decrease routine tasks, allowing a developer to focus on a more specific business feature. Consequently, 30 Symfony components are catalysing the development process. You can use a component independently and add custom modules without causing any issues to the architecture. Some Symfony components are used in a stand-alone way in other frameworks or plain PHP solutions.
Bundles
Essentially, bundles are like plugins. They are parcels full of files (JavaScripts, images, stylesheets and PHP files). Bundles are decoupled. You can reconfigure them for reuse for a variety of applications, which reduces the overall cost of development.
Both components and bundles are composable, allowing a developer to bolt together functionality. The benefits of having an application that consists of just the things you need are that it’s easier to make changes without breaking anything along the way. Meaning, you can tailor your solution to user scenarios and specific requirements and therefore have a flexible application.
Commercially supported
Symfony is one of a few commercially backed frameworks. You can attain certifications, attend conferences and receive official tutorials. They’re very serious in their intentions and this oozes credibility. Consequently, it's not hard to see why we use Symfony.
Reliable
This framework has proven itself where we’ve seen other frameworks diminish in popularity. Symfony’s longevity is ensured by the fact other systems and frameworks have chosen to take Symfony and build on top of it, including Drupal and Laravel.
Ease of testing
Symfony boasts more than 2,000 contributors, that’s an impressive number of diverse and knowledgeable people, all working on the code that will power your next project if you choose to base it on Symfony. Every new line of code written should be tested to ensure it’s stable for use in an application. Reusing bundles and just the components you need (all built on acceptable practices and established design patterns), combine for better maintainability and testing within Symfony.
Support for the long-term
Another reason why we use Symfony is that it's a stable and well-tested framework with regular updates. The most recent versions stay long-term supported and compatible with the newer releases: up to 3 years for some of the versions.
Supportive community spirit
What we love about Drupal is the community that comes with open source technology. Similarly, this scene exists in the Symfony world, too. One of the most influential factors in keeping a framework alive is the community driving it. Symfony boasts more than 2,000 contributors. That's an impressive number of diverse and knowledgeable people, all working on the code that will power your next project if you choose to base it on Symfony.
But, you might wonder why that’s important. PHP experts, as well as core developers, work on optimising the framework. The code improves thanks to the collaborative expertise. New components are created, issues resolved and people mentor and learn, pushing everyone forward.
Excellent documentation
A lot of technology is guilty of harbouring out-of-date or incomplete documentation. Symfony’s is up there with the best in comparison to alternative PHP frameworks.
Symfony’s technical documentation is well-written, with clear structure. It has examples and is updated with every new version. You’re able to find a detailed explanation for every component, even the development process as a whole.
Symfony and Drupal

Symfony offers many benefits to Drupal developers:
- We save time that would otherwise be used for solving issues or writing and maintaining code that’s already been written and tested by others.
- We don’t have to reinvent the wheel every time we start a new project. Symfony gives us access to tools for a lot of common tasks that recur for a lot of projects.
- To an extent, it encourages us Drupalists to use endorsed, tested and maintained code from elsewhere. Meaning, we step outside of our Drupal bubble to learn something new that adds value to the project. So we might even be able to step away from less-than-ideal Drupal solutions in favour of a Symfony solution.
- It promotes decoupled code.
- It also invites standardisation of best practises.
In Closing
We hope this sheds some light on what the framework is and why we use Symfony as a Drupal agency.
We’d love to chat about your upcoming projects. Contact us to learn how we can help!