ThisCalculator

Everyday

Mail Package Deliveries Home Assistant: How to Integrate

Updated · Standard formula, shown below

Mail Package Deliveries Home Assistant: How to Integrate

Yes, you can integrate mail and package deliveries into Home Assistant, and the most common approach is using a custom integration called USPS Integration (or similar for other carriers) combined with an automation that announces or displays delivery status. You enter your tracking numbers or connect your carrier account, and Home Assistant then gives you sensors for each package—showing status, estimated delivery date, and location—which you can use in dashboards, notifications, or voice announcements.

Background: Why Integrate Deliveries?

Home Assistant is a local-first smart home platform that connects devices and services into one dashboard. Package tracking is a natural fit because it answers a common question: “When will my package arrive, and has it been delivered?� Instead of checking a carrier website or app, you can see it on your dashboard, get a notification on your phone, or have your smart speaker announce “Your package from Amazon will arrive today.�

The integration works by pulling tracking data from the carrier’s public tracking APIs or from email receipts. It’s not an official integration from the carriers themselves; rather, it’s a community-built custom integration that you add to Home Assistant. This means you need to be comfortable installing custom components and occasionally troubleshooting when carrier websites change.

How It Works: The Main Integration Options

There are several ways to get package data into Home Assistant, each with different setup requirements and capabilities.

  • USPS Integration (custom) – This is the most popular for USPS packages. It uses your USPS account (with Informed Delivery) to fetch tracking data. It provides sensors for each package, including status, estimated delivery, and a summary of all packages.
  • UPS and FedEx integrations – Similar custom integrations exist for UPS and FedEx, often using your account credentials or tracking numbers. They work in the same way, giving you sensors for each package.
  • AfterShip or 17TRACK – These are third-party tracking services that aggregate multiple carriers. You can use their APIs (sometimes via a custom integration) to get tracking data for any carrier they support. This is useful if you receive packages from many different carriers.
  • Email-based tracking – Some integrations (like USPS Integration) can also parse delivery notification emails from your email account. This requires setting up an IMAP connection and creating filters.

All of these methods ultimately create sensors in Home Assistant that update periodically (usually every 15-30 minutes). The sensors have attributes like “status� (e.g., “In Transit�), “estimated_delivery�, and “last_updated�. You can then use these in automations.

How to Choose the Right Method

Your choice depends on which carrier you use most and how much effort you want to put into setup.

  • If you mostly get USPS mail – Start with the USPS Integration. It’s well-maintained and gives you both mail and packages.
  • If you get packages from multiple carriers – Consider an aggregator like AfterShip, which supports dozens of carriers. You’ll need to get an API key from AfterShip (free tier available).
  • If you prefer not to use third-party services – Use the carrier-specific integrations for each carrier you use. This means more setup but keeps your data local.
  • If you want a simple, low-maintenance option – Use an email-based integration that scans your inbox for shipping notifications. This works with any carrier but requires a dedicated email account or careful filtering.

Step-by-Step Setup (Using USPS Integration as Example)

Here’s a typical process for setting up the USPS Integration (the most common choice):

  1. Install the integration – In Home Assistant, go to Settings → Devices & Services → Add Integration, search for “USPS�, and follow the prompts. You’ll need to enter your USPS.com username and password (the same one you use for Informed Delivery).
  2. Enable Informed Delivery – If you haven’t already, sign up for Informed Delivery on the USPS website. This is free and gives you access to mail previews and package tracking data.
  3. Wait for initial sync – The integration will fetch your current packages and mail. It may take a few minutes to appear.
  4. Create a dashboard card – Add a sensor card to your dashboard to display package status. You can use the “mail� sensor for a summary, or individual package sensors.
  5. Set up an automation – For example, create an automation that sends a notification when a package is delivered: trigger when the package sensor’s status changes to “Delivered�, then send a notification to your phone.

If you use a different carrier, the steps are similar but with that carrier’s credentials.

Common Problems and Troubleshooting

Package tracking integrations are not always smooth. Here are the most common issues and how to fix them.

  • Login errors – The integration may fail to authenticate if you have two-factor authentication enabled on your carrier account. You may need to disable it or use an app password if available.
  • Packages not appearing – If you just ordered something, it may take a few hours for the carrier to register the tracking number. Also, the integration only fetches packages that are in your account or that you’ve manually added.
  • Outdated status – The integration updates on a schedule (e.g., every 30 minutes). If you need more frequent updates, you can adjust the scan interval in the integration’s options.
  • Carrier website changes – Since these are community integrations, they can break if the carrier changes their website structure. Check the integration’s GitHub page for updates and known issues.
  • Multiple packages – If you have many packages, the integration may create a lot of sensors. Use the summary sensor for a quick glance, and only display individual packages in automations when needed.

Alternatives to Custom Integrations

If you don’t want to deal with custom integrations, there are simpler but less powerful alternatives.

  • Manual tracking numbers – You can create a simple input_text helper in Home Assistant and manually paste a tracking number. Then use a RESTful sensor to query a public tracking API (like the one from AfterShip) to get status. This is more work but doesn’t require a custom integration.
  • IFTTT or Zapier – You can use these services to watch your email for shipping notifications and then send a webhook to Home Assistant. This is a bridge solution that adds a dependency on a cloud service.
  • Use a smart doorbell or camera – Some people use a camera to detect when a package is left at the door. This doesn’t give you tracking info, but it tells you when a delivery happens. You can combine this with a simple notification automation.

Safety and Privacy Considerations

When you integrate package tracking, you’re giving Home Assistant access to your carrier account or email. That means your delivery data is stored locally (if you use a local integration) or on a third-party server (if you use an aggregator).

  • Local vs cloud – Carrier-specific integrations like USPS Integration store data locally in Home Assistant. Aggregators like AfterShip store data on their servers, so you’re trusting them with your tracking info.
  • Account credentials – You’re entering your carrier password into Home Assistant. Make sure your Home Assistant instance is secure (use HTTPS, strong passwords, and two-factor authentication).
  • Email scanning – If you use email-based tracking, you’re giving the integration access to your email. Use a dedicated email account for shipping notifications to limit exposure.
  • Physical security – Announcing “package deliveredâ€� on a speaker could alert someone nearby that you’re not home. Consider using private notifications (phone) instead of public announcements when you’re away.

Frequently Asked Questions

Can I track packages from multiple carriers at once?

Yes, you can install multiple carrier-specific integrations (e.g., USPS, UPS, FedEx) and they will each create their own sensors. Alternatively, use an aggregator like AfterShip that supports many carriers in one integration, but that requires an API key and sends data to a third party.

Will I get a notification when my package is delivered?

Yes, you can create an automation that triggers when the package sensor’s status changes to “Delivered�. For example, use the state trigger “package_sensor� to “Delivered� and send a notification to your phone or announce it on a smart speaker.

Do I need a paid subscription?

No, the custom integrations are free. However, some third-party tracking services (like AfterShip) have free tiers with limits on the number of packages tracked. The carrier-specific integrations are completely free.

Can I track packages that are not linked to my account?

Yes, most integrations allow you to manually add tracking numbers. In the USPS Integration, you can add a tracking number via the “Add Package� service. The integration will then monitor that package even if it’s not in your Informed Delivery account.

Is it possible to track international packages?

Yes, but it depends on the carrier. USPS Integration can track some international packages that are handled by USPS. For other international carriers, you may need to use an aggregator that supports them, or a carrier-specific integration if one exists.

What if the integration stops working after a Home Assistant update?

This can happen if the integration is not updated to be compatible with the latest Home Assistant version. Check the integration’s GitHub page for updates, and consider using HACS (Home Assistant Community Store) to manage updates more easily. If it’s broken, you may need to wait for a fix or use an alternative method temporarily.

Related

Method: the standard formula for this calculation, rounded as each result states. See how the calculators work or report an error.