Hardware FixRecommendedDevice not working? Your driver may be the problemCheck updates for common hardware issues.Fix DriversOctober DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsSlow PC?RecommendedPC slow today? Run a repair scan before it gets worseResolve common Windows issues and optimize system performance.Scan Now×
Skip to content
World desk3 min

How to Split a 2,000-Line Home Assistant automations.yaml into 8 Files

Use a labeled automation block and !include_dir_merge_list to split manual Home Assistant automations across eight topic files without losing the UI-managed workflow.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

To split manually maintained Home Assistant automations into eight topic files, keep the UI-managed automations.yaml include in place and add a second, labeled automation block that merges lists from an automations/ directory. Put each automation under a YAML list item beginning with -, then validate the configuration and confirm the automations load on your installation.

Use a separate directory for the eight manual files

In configuration.yaml, keep the standard automation include for the UI-managed file and add a separately labeled block for the hand-maintained files:

As an Amazon Associate I earn from qualifying purchases.

# Automations created or maintained in the Home Assistant UI
automation: !include automations.yaml

# Hand-maintained automations, split by topic into directory files
automation manual: !include_dir_merge_list automations/

Both top-level keys must begin at column one; do not include a leading space before automation:. The separate automation manual label lets Home Assistant load another automation block alongside the UI-managed one. The Home Assistant configuration-splitting guide demonstrates this pattern.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Create an automations/ directory beside your configuration file and organize the files by the categories that fit your setup. For example:

#1 Best Overall
Home Assistant Green | Smart Home hub with Advanced Automation | Official Home Assistant Hardware
  • 💡 EASIEST WAY TO GET STARTED WITH HOME ASSISTANT - With Home Assistant already installed, it only requires plugging the included power supply and Ethernet cable to get started.
  • ✅ OFFICIAL - This official Home Assistant hardware is built and supported by Nabu Casa, the team driving the development of Home Assistant.
  • 🏡 DESIGNED FOR THE HOME - The small, fanless, and silent design packs a quad-core processor, 32GB of storage, and 4GB of RAM.
  • 📱 ONE HUB TO CONTROL THE WHOLE HOME - Cut down hub and app clutter and control your whole home from Home Assistant Green.
  • 🤖 AUTOMATE EVERYTHING - Make all the devices in your home work in harmony - have your lights dim when you start watching a movie, or turn off your heat when you’re away from home.
automations/
  01_lighting.yaml
  02_climate.yaml
  03_presence.yaml
  04_security.yaml
  05_notifications.yaml
  06_energy.yaml
  07_media.yaml
  08_miscellaneous.yaml

Those names and the count of eight are organizational choices, not Home Assistant requirements. Directory includes scan files ending in .yaml; files ending in .yml are ignored.

Format each file as a list of automations

!include_dir_merge_list is a good fit when each topic file may contain multiple automation entries. Start every entry with a hyphen, and keep its automation fields nested underneath:

Rank #2
CanaKit Raspberry Pi 5 Starter Kit PRO - Turbine Black (128GB Edition) (8GB RAM)
  • Includes Raspberry Pi 5 with 2.4Ghz 64-bit quad-core CPU (8GB RAM)
  • Includes 128GB Micro SD Card pre-loaded with 64-bit Raspberry Pi OS, USB MicroSD Card Reader
  • CanaKit Turbine Black Case for the Raspberry Pi 5
  • CanaKit Low Noise Bearing System Fan
  • Mega Heat Sink - Black Anodized
- id: evening_living_room_lights
  alias: Evening living room lights
  triggers:
    - trigger: sun
      event: sunset
  actions:
    - action: light.turn_on
      target:
        entity_id: light.living_room

Move each automation without changing its logic, ID, or entity references. Preserve stable, unique IDs where they exist, and check the automation schema against the Home Assistant version you run. The YAML automation guide says UI-editor automations need IDs and that automations.yaml remains a list.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Choose an include method that matches the file shape

Include method Expected shape and use
!include_dir_merge_list Merges lists from multiple files. Use it for grouped files containing one or more automation entries each.
!include_dir_list Each file contributes one list entry. This is suited to one automation per file, not several grouped automations in each of eight files.
!include_dir_named Creates a mapping keyed by file names. Use it only when the receiving configuration expects that shape.
Packages Groups configuration by feature or subsystem, including automations and other integration domains, under homeassistant: packages:. See the packages documentation.

Keep the UI-managed file separate

Home Assistant’s YAML automation guide states: “The UI will write your automations to automations.yaml. This file is managed by the UI and should not be edited manually.” Keeping that file attached to the standard automation: include preserves the UI editing workflow while the additional block loads your manual directory files.

Rank #3
CanaKit Raspberry Pi 4 4GB Starter PRO Kit - 4GB RAM
  • Includes Raspberry Pi 4 4GB Model B with 1.5GHz 64-bit quad-core CPU (4GB RAM)
  • Includes Pre-Loaded 32GB EVO+ Micro SD Card (Class 10), USB MicroSD Card Reader
  • CanaKit Premium High-Gloss Raspberry Pi 4 Case with Integrated Fan Mount, CanaKit Low Noise Bearing System Fan
  • CanaKit 3.5A USB-C Raspberry Pi 4 Power Supply (US Plug) with Noise Filter, Set of Heat Sinks, Display Cable - 6 foot (Supports up to 4K60p)
  • CanaKit USB-C PiSwitch (On/Off Power Switch for Raspberry Pi 4)

If an automation should remain editable through the UI, follow Home Assistant’s migration guidance: copy it into automations.yaml and give it a unique id. For secret-bearing automations, be aware that secrets are unsupported in the UI YAML editor for automations and scripts. Home Assistant’s secrets documentation describes using a separate included YAML file; that file is read-only in the frontend. Secret values may also be visible in UI YAML and trace views.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Move the automations and verify the result

  1. Back up your configuration. Keep a recoverable copy before changing the automation files.
  2. Inventory and sort. Assign each hand-maintained automation to one of the eight topic files. Leave UI-managed entries in automations.yaml.
  3. Create YAML lists and move entries. Start every automation with -. Preserve its logic, IDs, and entity references, and avoid placing the same automation in more than one file.
  4. Update configuration.yaml. Retain automation: !include automations.yaml if you need the UI editor, and add automation manual: !include_dir_merge_list automations/ as a separate top-level block.
  5. Validate and load. Use the configuration validation method available for your installation, then reload automations or restart Home Assistant if required for your installation and the change. The configuration-checking documentation recommends validating configuration after edits.
  6. Confirm operation. Check that the expected automations appear, and inspect traces or logs for entries that are missing or fail to run.

Validation and reload behavior can vary by installation type and Home Assistant release; check the documentation for the version you have installed rather than assuming one reload procedure applies everywhere.

Quick Recap

Bestseller No. 2
CanaKit Raspberry Pi 5 Starter Kit PRO - Turbine Black (128GB Edition) (8GB RAM)
CanaKit Raspberry Pi 5 Starter Kit PRO - Turbine Black (128GB Edition) (8GB RAM)
Includes Raspberry Pi 5 with 2.4Ghz 64-bit quad-core CPU (8GB RAM); CanaKit Turbine Black Case for the Raspberry Pi 5
$259.95
Bestseller No. 3
CanaKit Raspberry Pi 4 4GB Starter PRO Kit - 4GB RAM
CanaKit Raspberry Pi 4 4GB Starter PRO Kit - 4GB RAM
Includes Raspberry Pi 4 4GB Model B with 1.5GHz 64-bit quad-core CPU (4GB RAM); Includes Pre-Loaded 32GB EVO+ Micro SD Card (Class 10), USB MicroSD Card Reader
$159.99
Best Value
RasTech Raspberry Pi 5 8GB Kit with Active Cooler and Pi5 Case
  • 【What you Get】You will get 1*Pi 5 8GB Single Board,1*RasTech Case,1*Active Cooler,1*Screwdriver,1*Installation instructions,12-month free warranty, lifetime service, 24-hour prompt and friendly response.
  • 【More Connectors】There are two USB 3.0 ports(5Gbps simultaneously) and two USB 2.0 ports, which triple total bandwidth ,support any combination of up to two cameras or displays. Peak SD card performance is doubled through support for the SDR104 high-speed mode. It provides a smooth desktop experience for you. Offer Gigabit Ethernet and a PCIe interface, along with dual-band Wi-Fi and Bluetooth 5.0/BLE wireless capability. The RasTech Pi 5 Kit use the new 27W 5.1V 5A USB-C power connector.
  • 【 Support Dual 4Kp60 Display 】Each of the two microHDMI sockets can control a 4K display at 60 Hertz, now support HDR, offering super HD video for media streaming projects. RPi 5 is the first RPi model that comes with a PCI Express port (PCIe 2.0 x1 with 500 MB/s) to attach SSDs (requires separate M.2 HAT).
  • 【 Excellent Chips And Applications】Pi 5 is a full-size Pi computer using silicon built in-house at Pi. The RP1 “southbridge” provides the bulk of the I/O capabilities for Pi 5. Pi 5 is more friendly and convenient in the development of Internet of Things, Web development, machine identification, automatic control and other electronic equipment applications and network.
  • 【 Faster CPU, Better GPU 】 Pi 5 features a Broadcom BCM2712 64-bit quad-core Arm Cortex-A76 processor running at 2.4GHz, it delivers a 2–3× increase in CPU performance relative to RaspberryPi 4. The 800MHz VideoCore VII GPU is compatible to OpenGL ES 3.1 and Vulkan 1.2, substantial uplift in graphics performance. Pi 5 Offers lightning-fast CPU speed, a PCI Express interface, a Real Time Clock (RTC) and a power button and runs significantly cooler than Pi 4.
Rank #4
RasTech Raspberry Pi 5 8GB Kit 64GB Edition with Active Cooler,27W GaN 5.1V5A USB-C Power Supply,Pi5 8GB Board,64GB Card Readers Kit,Pi 5 Case,Dual 4K Micro HD Out Cables and User Manual
  • Pi5 8GB Pack: RasTech Pi 5 8GB kit includes 1 x Pi5 8GB board ,1 x 64GB Card, 2 x Card Readers,1 x Active Cooler,1 x Case for Pi5, 2 x 4K Micro HD Out Cable,1 x GaN 27W 5A USB-C Power supply,1 x Screwdriver and 1 x instructions.
  • Pi5 8GB Board: The Pi5 board is equipped with a 64-bit quad-core Arm Cortex-A76 processor running at 2.4GHz and an 800MHz VideoCore VII GPU with support for OpenGL ES 3.1 and Vulkan 1.2, which delivers a significant increase in graphics performance. Dual HD Out 4Kp60 display outputs and a built-in dual 4-channel MIPI camera/display transceiver provide state-of-the-art camera support. The Pi 5 offers a 2-3 times increase in CPU performance compare to Pi4.
  • Important Graphics Features: Equipped with an 800MHz VideoCore VII GPU and providing better graphics performance, suitable for multimedia applications,gaming,and graphics intensive tasks.Provides 1 UART interface,1 card slot that supports high-speed operation, 2 USB. 3 0.5 ports that support synchronous 0Gbps operation,2 USB 2.0 port ports,2 4Kp60 display outputs that support HDR.Built-in dedicated dual 4-channel 1Gbps MIPI DSI/CSI connectors,triple the total bandwidth.
  • Cooling Kit for Pi 5: Compatible with Active Cooler for Raspberry Pi5, It can provide Pi 5 board with better cooling effect in using. The Case can accurately access usb-c power jack,Micro HD Out ports, usb ports, Ethernet jack, card slot, power button, 4-lane MIPI DSI/CSI connectors and so on, and it also supports installation of cooling fan.
  • 64GB Card Kit and GaN 27W USB-C Power Supply: With extra 64GB card to store more files and card readers for multiple medium, keep better performance for Raspberry Pi 5, 27W USB C Power Supply is Compatible with Pi5 8GB, offers a variety of output voltage options, including 5.1V at 5A, 9.0V at 3.0A, 12.0V at 2.25A, and 15.0V at 1.8A, providing for different device requirements.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Leave a Reply

Your email address will not be published. Required fields are marked *

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More from the Wire

  1. World desk4 min
    How to Spot an AI Voice Scam Before Sending MoneyDon’t rely on how a caller sounds. Pause, call back through a known number, and verify the emergency with another trusted person before sending money.
  2. Mountain View desk4 min
    Google’s SynthID Detector: How to Check AI-Generated Images, Video and AudioGoogle’s SynthID Detector looks for an embedded watermark in supported images, video and audio. Here is what its results do—and do not—show.
  3. Redmond desk20 min
    How to create a link to File or Folder in Windows 11Windows 11 gives you several ways to point to a file or folder without moving or duplicating it. You can create a desktop shortcut,…
Recommended PC Tool
Recommended PC Tool
Windows Errors? Fix Them Before They SpreadFree repair scan
Crashes, No Sound, or Screen Glitches?Free driver scan

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.