Описание
FluentSnippets is the fastest and most secure code snippets plugin for WordPress, a high-performance way to add custom code to your site without editing your theme’s functions.php file. Easily insert header and footer scripts, run PHP code snippets, and add custom CSS, JavaScript, and HTML with powerful conditional logic.
⭐ 100% free and open source. No «Pro» version, no upsells, no feature held back behind a paywall.
Unlike every other code snippet plugin, FluentSnippets stores your snippets in flat files and loads them natively, so it runs zero database queries and never slows down your site. No bloated database tables, no extra SQL injection surface, just safe, native, lightning-fast code execution.
Whether you want to add Google Analytics, a Facebook Pixel, ads.txt or banner ad codes, conversion tracking scripts, custom CSS tweaks, or complex PHP functionality, FluentSnippets makes it safe, secure, fast, and hassle-free. It is the perfect lightweight alternative to editing functions.php or using heavier, database-driven code snippet managers.
👉 Website: Official Website
👉 Community: Join Community
👉 Github: View source & contribute
Simple for Beginners, Powerful for Developers
Adding a snippet takes seconds: open the editor, paste or write your code, choose where it should run (everywhere, admin only, front-end only, or based on conditional logic), and save. A built-in syntax highlighter and smart error handling guide you along the way. If a snippet ever causes a fatal error, FluentSnippets automatically deactivates it so your site stays online instead of breaking. You can organize snippets with tags, switch them on or off with a single click, and export or import them between sites in seconds.
100% Free & Open Source: No Upsells, No «Pro» Version
FluentSnippets is completely free and fully open source under the GPL. There is no premium version, no locked or «Pro-only» features, no upsells, and no email-gated downloads. Every single feature is included for everyone, on every site, forever. The full source code lives on GitHub, so developers can read the code, audit it for security, request features, report bugs, or contribute directly via pull requests. It is built and actively maintained by the team behind FluentCRM, Fluent Forms, and FluentSMTP.
From Quick Tweaks to Advanced Customizations
From simple tweaks to advanced development, FluentSnippets handles it all. Use it to add Google Tag Manager and tracking pixels, register custom shortcodes, create custom functions, disable comments or emojis, remove unwanted admin notices, add JSON-LD schema markup, or run any PHP snippet you would normally drop into functions.php. CSS snippets even support the WordPress Block Editor (Gutenberg), so you can style your site with a familiar editing experience. Every snippet runs only where you tell it to, thanks to granular conditional logic based on post type, page URL, user role, login status, and more, so your custom code stays fast, targeted, and easy to manage.
How FluentSnippets Works: Zero Database Queries
Every other code snippets plugin keeps your code in the database and queries it on every single page load. FluentSnippets does not. Each snippet is stored as a real PHP file, with its title, description, snippet type and conditional logic recorded in a doc block at the top of that file. Those doc blocks are parsed once and cached into an index, so nothing is re-parsed on later requests. At runtime the plugin simply includes the files you activated, on the action hook you chose, exactly the way WordPress loads a plugin.
The result is zero database queries at runtime. Not «a few». None at all. There is no snippets table to bloat your database, nothing for a SQL injection in some other plugin to reach, and no query for your host to slow down. It is a native, secure-by-design architecture, and it makes FluentSnippets the fastest code snippets plugin in its category.
Функции
- Файловые сниппеты: Все сниппеты надёжно сохраняются в файловой системе и загружаются напрямую — без запросов к БД. Это безопасно, надёжно и сверхбыстро.
- Кастомные сниппеты: Пишите код на PHP, JS, CSS, HTML и др. Группируйте сниппеты по категориям, тегам и пр.
- Продвинутая условная логика: Выполняйте сниппеты только при соблюдении условий: тип записи, дата, URL, роль пользователя и многое другое.
- Automatic Error Handling: If a snippet ever triggers a fatal error, the error handler catches it, deactivates that one snippet, and tells you which line caused it, so a bad snippet never takes your site down.
- Safe Mode Recovery: If custom code ever locks you out of wp-admin, a Safe Mode URL switches every snippet off so you can get back in and fix it. No FTP, no database surgery.
- Export & Import: Move snippets between sites, or keep a portable backup of them, in a couple of clicks.
- Block Editor Support: CSS snippets work inside the WordPress Block Editor (Gutenberg), so styling your site happens in a familiar place.
- Пользовательские шорткоды: Для каждого сниппета создаётся уникальный шорткод — вы можете использовать его как динамический блок контента на всём сайте и удобно управлять им.
- Автономный режим (Stand-alone Mode): Самая интересная функция. Добавьте сниппеты, активируйте автономный режим — затем вы можете удалить сам плагин, а сниппеты продолжат работать через архитектуру mu-plugins. При повторной активации плагина вы снова сможете управлять сниппетами как раньше.
- Dark Mode: A full dark theme across every screen, switchable from the admin bar and remembered between visits. The setting is shared with the other Fluent plugins, so switching it in one switches it in all of them.
Мощная «умная» условная логика
Мы добавили интеллектуальную условную логику, позволяющую вам точно выбирать, где вы хотите выполнить свой код. Эта условная логика включает в себя
- Состояние входа пользователя или его роль
- Типы страниц
- Типы записей
- Правила по таксономии или термину
- По URL страницы/записи
- Целевые страницы, записи и произвольные типы записей (CPT)
- Условия по дате
- Правила на основе тегов/списков FluentCRM для текущего контакта
Conditions are group-based: you can add several groups, each with its own set of rules, and the snippet runs whenever any one group matches.
Типы сниппетов
FluentSnippets поддерживает 4 типа сниппетов — выберите нужный в меню создания.
Тип сниппета: Функции (PHP) — для кода, который вы обычно помещаете в functions.php темы.
Используйте его для создания функций, классов, подключения к хукам и фильтрам WordPress и пр.
Тип сниппета: Контент (PHP + HTML) — для вставки контента в шапку, подвал, до/после контента записи и т.д. Поддерживает PHP, HTML, JS и CSS.
Тип сниппета: CSS — используйте для добавления кастомных стилей.
Тип сниппета: JS — используйте для добавления кастомного JavaScript на сайт.
Популярные сценарии использования
- Добавление кастомного PHP-кода для расширения функционала
- Добавление кодов в шапку и подвал (Google Analytics, Pixel, рекламные коды)
- Кастомные CSS-стили для конкретных типов записей/страниц
- Кастомные JavaScript-коды
- Динамическое размещение контента в различных местах, например, до / после публикации контента или нижнего колонтитула
- Динамические шорткоды
Другие плагины от той же команды
- FluentCRM – Email Marketing, Newsletter, Email Automation and CRM Plugin for WordPress
- Fluent Forms – Fastest WordPress Form Builder Plugin
- Ninja Tables – Best WP DataTables Plugin for WordPress
- Ninja Charts – Best WP Charts Plugin for WordPress
- WPPayForm — Stripe Payments Plugin for WordPress
- Mautic Integration For Fluent Forms
- Fluent Forms PDF — PDF Entries for Fluent Forms
- FluentSMTP — WordPress Mail SMTP, SES, SendGrid, MailGun Plugin
ВКЛАД
If you want to contribute to this project or just report a bug, you are more than welcome. Please check repository from Github. FluentSnippets was known as Easy Code Manager before. We have rebuild & rebranded it to FluentSnippets.
Скриншоты







Установка
Этот раздел описывает, как установить плагин и приступить к его использованию.
- Просто найдите FluentSnippets в каталоге плагинов WordPress и нажмите «Установить» и «Активировать».
Часто задаваемые вопросы
-
Yes. FluentSnippets lets you easily insert code into your site’s header and footer, such as Google Analytics, Facebook Pixel, Google Tag Manager, ad codes, and any other custom HTML, JavaScript, or tracking scripts. You can add them globally or only on specific pages using conditional logic.
-
What types of code snippets can I add?
-
You can add PHP code snippets (just like your theme’s functions.php), Content snippets (PHP + HTML for header, footer, before/after post content, and more), Custom CSS snippets, and Custom JavaScript snippets, all from one clean interface with syntax highlighting.
-
Is FluentSnippets a good alternative to other code snippet plugins?
-
Absolutely. Most code snippet plugins store your snippets in the database and run SQL queries on every page load, which is slow and increases your attack surface. FluentSnippets stores everything in flat files and loads them natively with zero database queries, making it a faster, safer, and more lightweight alternative for managing custom code.
-
Can I use FluentSnippets instead of editing functions.php?
-
Yes. FluentSnippets is the safe way to add custom code without touching your theme’s functions.php file. Your snippets survive theme updates, can be activated or deactivated with one click, and the built-in error handler prevents a bad snippet from breaking your site.
-
Where are my code snippets stored?
-
Each snippet is saved as a real PHP file in
wp-content/fluent-snippet-storage, not in a database table. That means you can read them, back them up with your normal file backups, and move them between sites by copying files. If you need them somewhere else, theFLUENT_SNIPPETS_STORAGE_DIRconstant inwp-config.phpwill point the plugin at a different directory. Your snippets also survive theme changes and theme updates, because nothing lives in your theme. -
What happens if a code snippet breaks my site?
-
FluentSnippets watches for fatal errors. If a snippet causes one, the plugin deactivates that specific snippet automatically and reports which snippet and which line was responsible, so your site stays online instead of showing a white screen. If you ever do get locked out of wp-admin, a Safe Mode URL switches every snippet off at once so you can get back in. No FTP access or database editing required.
-
Can my snippets keep running if I delete the plugin?
-
Yes. Turn on Stand-alone Mode and your snippets keep running through the mu-plugins architecture even after the plugin is deactivated and deleted. Reinstall FluentSnippets later and you can manage them again exactly as before.
-
Can I export and import snippets between sites?
-
Yes. You can export your snippets to a file and import them into another WordPress site in a couple of clicks. That is useful for reusing the same set of customizations across sites, or for keeping a portable backup.
-
Какова основная функция FluentSnippets и как он может быть полезен моему сайту?
-
Основная функция FluentSnippets — позволить легко добавлять кастомные кодовые сниппеты на сайт WordPress без прямого редактирования файлов основной или дочерней темы.
Плагин предоставляет удобный интерфейс для добавления, управления и выполнения кастомных PHP-, HTML-, JS- и CSS-сниппетов. Это особенно ценно: ваши изменения сохранятся даже после обновления темы.
Нужно добавить простую правку CSS, встроить HTML в шапку или подвал, или запустить сложный PHP-скрипт? FluentSnippets справится с этим — быстро, безопасно и эффективно.
-
Нужны ли навыки программирования для использования этого плагина?
-
Хотя некоторые базовые знания в области программирования, безусловно, могут быть полезны при использовании этого плагина, это не является абсолютно необходимым. FluentSnippets разработан таким образом, чтобы быть удобным и доступным для широкого круга пользователей.
Цель — упростить добавление кастомного кода на ваш сайт. Это означает, что вы можете легко вставлять PHP, JavaScript, HTML или CSS без прямого редактирования файлов темы, что может быть сложно и рискованно для новичков.
-
Замедлит ли FluentSnippets мой сайт?
-
Quite the opposite. Unlike other code snippets plugins, FluentSnippets does not use the database to store your custom snippets. It stores them as flat files and executes them natively from the file system, which is extremely fast. It runs no database queries at all while your site is serving pages.
Отзывы
Участники и разработчики
«FluentSnippets – High-Performance Code Snippets, Header & Footer Code, Custom CSS & PHP Code Manager» — проект с открытым исходным кодом. В развитие плагина внесли свой вклад следующие участники:
Участники«FluentSnippets – High-Performance Code Snippets, Header & Footer Code, Custom CSS & PHP Code Manager» переведён на 8 языков. Благодарим переводчиков за их работу.
Заинтересованы в разработке?
Посмотрите код, проверьте SVN репозиторий, или подпишитесь на журнал разработки по RSS.
Журнал изменений
10.56 — Aug 12, 2026
- Added a dark mode, switchable from the admin bar and shared with the other Fluent plugins
- Redesigned every screen: the snippet list, the editor, Settings and About
- Improved colour contrast throughout, so every screen meets WCAG AA in both light and dark
- Fixed a click in the code editor selecting the whole snippet instead of placing the cursor
- Fixed error text on the snippet list not showing in the error colour
- Added inactive snippets count and filter reset options when no snippets match the current filter
- Fixed the welcome screen being skipped on a fresh install when «Hide Inactives» was enabled
- Fixed a JavaScript error on the dashboard when the site has no snippets
- Fixed pagination total count so sites with more than 200 snippets can reach every page
- Changed Color Schema and new branding for FluentSnippets
10.55 — Jun 28, 2026
- Added «Hide Inactives» filter to quickly hide inactive snippets on the dashboard
- Added Custom Snippets Storage Path support via constant
- Invalidate OPcache after writing snippet engine files for reliable updates
- Fixed RTL code formatting issue in the editor
- Fixed string concatenation issue
- UI / UX Improvements
10.53 — Jun 22, 2026
- Fixed Block Editor CSS Issue
10.52 — Jan 21, 2026
- Added Block Editor Support for CSS
- Use Ajax endpoint to create and edit snippets for better Usability
- Enhance handleShortcode to retain user arguments
- UI / UX Improvements
10.51 — May 11, 2025
- Безопасность: Добавлена проверка nonce при экспорте/импорте сниппетов (спасибо Patchstack)
- Исправлена ошибка в условной логике «Пользователь / состояние входа»
- Исправлена проблема с датой при создании нового сниппета
10.50 — Apr 27, 2025
- Добавлены функции экспорта и импорта
- Исправлены проблемы при миграции сайта
- Добавлены строки интернационализации почти для всего интерфейса
- Добавлена мягкая переноска строк в редакторе
- Добавлена поддержка сочетания Command + S для сохранения сниппетов
10.34 — May 05, 2024
- Исправлены проблемы с условиями для скриптов
- Добавлена загрузка сниппетов как файлов
- Исправлена совместимость с PHP 8.x
10.33 — Jan 25, 2024
- Исправлена ошибка с фрагментом кода
10.32 — Jan 05, 2024
- Исправлена интеграция с FluentCRM
- Добавлены подробные сообщения об ошибках в сниппетах
- Улучшения в работе с REST API
- Улучшения интерфейса и пользовательского опыта
10.31 — December 18, 2023
- Исправлена опечатка в условной логике
- Добавлено видео-руководство
10.3 — December 18, 2023
- Новый дизайн и фирменный стиль
- Новый интерфейс и UX
10.1
- Полная переработка плагина для повышения производительности
- Новый интерфейс и UX
10.0
- Исправлено: стили для WordPress 5.5
- Улучшение: обновлён ACE Editor до версии 1.4.12
- Улучшение: доработан менеджер сниппетов
- Улучшение: добавлена опция placeholder
- Добавлена опция отключения автоотступа
- Добавлено: новые языковые режимы
- Исправлено: двойной пробел превращался в точку на мобильных клавиатурах
- Исправлено: Backspace не работал на некоторых мобильных клавиатурах
