---
title: "DHL Express"
description: "The DHL Express shipping plugin connects your J2Commerce store directly to DHL's MyDHL API."
url: "https://www.docs.j2commerce.com/v6/shipping-methods/shipping_dhlexpress"
markdown_url: "https://www.docs.j2commerce.com/v6/shipping-methods/shipping_dhlexpress.md"
last_updated: "2026-11-17T15:48:50+00:00"
version: "J2Commerce 6"
breadcrumbs:
  - title: "Home"
    url: "https://www.docs.j2commerce.com/"
  - title: "J2Commerce 6"
    url: "https://www.docs.j2commerce.com/v6"
  - title: "Shipping Methods"
    url: "https://www.docs.j2commerce.com/v6/shipping-methods"
  - title: "DHL Express"
    url: "https://www.docs.j2commerce.com/v6/shipping-methods/shipping_dhlexpress"
---

# DHL Express

The DHL Express shipping plugin connects your J2Commerce store directly to DHL's MyDHL API. Instead of showing customers a flat delivery fee, your checkout pulls live DHL Express rates once a shipping address is entered, with the actual service names, transit times, and prices DHL would charge you for that shipment. From the order screen you can also generate a DHL waybill (shipping label) and give the customer a real DHL tracking number, without leaving your Joomla admin.

This plugin is built for stores that ship internationally or need DHL's speed and reliability, and want checkout rates that match what DHL actually bills.

## Requirements

- PHP 8.3.0 or later
- Joomla 6.x
- J2Commerce 6.6.4 or later
- A DHL Express business account with MyDHL API credentials (API Key, API Secret, and Account Number) issued by DHL through the DHL Developer Portal. J2Commerce does not provide these.

---

## Purchase and Download

**Step 1:** Go to our [DHL Express on the J2Commerce Extensions Store](https://www.j2commerce.com/extensions/shipping-plugins/dhl-express) **->** **Extensions**

**Step 2:** Locate the **DHL Express** shipping plugin **->** click **View Details** **-> Add to cart -> Checkout**.

**Step 3:** Go to your **My Downloads** under your profile button at the top right corner and search for the plugin. Click **Available Versions -> View Files -> Download**

---

## Install the Plugin

In the Joomla admin, go to **System -> Install -> Extensions**

Upload the `shipping_dhlexpress.zip` package file, or use the **Install from URL** option.

> **Info:** DHL Express needs J2Commerce 6.6.4 or later to be installed and enabled. Install or update J2Commerce first.

---

## Enable the Shipping Method

Shipping plugins are not managed from the Apps screen. DHL Express is enabled and configured from the **Shipping Methods** screen, and it must also be published as a Joomla plugin.

**Option A:** Go to the **J2Commerce** icon at the top right corner **-> Setup -> Shipping Methods**

**Option B:** Go to **Components** on the left sidebar **-> J2Commerce -> Dashboard -> Setup -> Shipping Methods**

Look for **DHL Express Delivery**, click the **X**, and it turns into a green checkmark. It is now enabled and ready for setup.

If it does not turn green, check **System -> Manage -> Plugins**, filter by **j2commerce**, and confirm **Shipping - DHL Express** is published.

> **Tip:** Click the **Toggle Inline Help** button in the toolbar to show a description below each field.

---

## Configure the Shipping Method

Click the **DHL Express Delivery** title next to the green checkmark to open the settings. They are organized into tabs.

### Basic

**Checkout Logo:** Image shown next to the DHL Express delivery option at checkout. A default DHL Express logo is pre-filled.

### DHL Credentials

**Test Mode:** Set **Yes** to call the DHL test endpoint. Set **No** on a live store.

**API Key:** Your DHL MyDHL API key (Basic Auth username). Issued from the DHL Developer Portal.

**API Secret:** Your DHL MyDHL API secret (Basic Auth password).

**DHL Account Number:** Your DHL Express account number, tied to your delivery contract, not the API portal account.

> **Tip:** Start with **Test Mode** set to **Yes** and confirm rates come back correctly before switching to live credentials. API Key, API Secret, and Account Number must have been issued together, or every rate request fails.

### Origin & Geo Zone

**Origin Country:** Country your shipments dispatch from. Used as the rate quote origin.

**Origin City:** City your shipments dispatch from. Required by the DHL rate API.

**Unit of Measurement:** Choose **Metric (kg, cm)** or **Imperial (lb, in)**. Must match the units configured on your DHL account.

**Geo Zone:** Restrict DHL Express rates to a Geo Zone. Leave blank to offer DHL on every destination.

> **Info:** Origin Country and Origin City are both required. Without them, DHL Express skips rating at checkout and customers see no DHL option.

### Services

**DHL Service Codes:** Pick the DHL Express services to offer at checkout (for example DOMESTIC EXPRESS 12:00, EXPRESS WORLDWIDE, EXPRESS 9:00). Only rates for the selected service codes display. Leave empty to allow every service DHL returns for the route.

**Network Type:** Restrict rates to **Air Products (Time Definite)**, **Road Products (Day Definite)**, or **Both Air and Road**. Both is the default.

> **Tip:** Not every DHL service is available on every route or account. If a selected service never appears at checkout, DHL did not offer it for that origin and destination. Try widening your selection.

### Display & Pricing

**Show Transit Time:** Set **Yes** to display the transit time in business days under each DHL rate.

**Handling Cost:** Optional flat amount added on top of every DHL rate. It is always added in your store's currency and is never converted.

**Tax Profile:** Tax profile applied to the DHL rate at checkout. Leave blank to skip delivery tax.

**Debug Mode:** Set **Yes** to write rate requests and responses to `administrator/logs/shipping_dhlexpress.php`. Disable on production.

### DHL Waybill / Label

**DHL Product Code:** Fallback DHL Express product code used only when the order has no stored product code. Normally the label reuses the product the customer was quoted and charged at checkout.

**Label Format:** **PDF** for standard laser/inkjet printing, **ZPL** or **EPL** for thermal label printers.

**Shipper Company Name:** Company or person name printed on the DHL label as the sender. Defaults to your store name if left blank.

**Shipper Phone Number:** Phone number printed on the DHL label for the sender (digits only, no spaces).

**Allowed Order Statuses:** Order statuses on which the **Create Label** button appears. Select one or more; leave empty to show the button on every order.

> **Info:** DHL Express allows one label per order. Once a tracking number is saved, the **Create Label** button is replaced with the tracking number. Clear the tracking number on the order before creating a new label.

### Customs (International)

These fields only matter for cross-border shipments. Customs data is skipped for domestic shipments and for shipments moving entirely within the EU customs union.

**Incoterm:** Trade term declared to customs on cross-border shipments. **DAP** (recipient pays duties/taxes) is the common default; **DDP** means you prepay duties and taxes.

**Export Reason:** Reason for export declared on each customs line item. Use **Sale of Goods** for normal orders.

**Country of Manufacture:** Two-letter ISO country code declared as the goods' country of origin (for example `GB`, `DE`, `CN`). Leave blank to use the origin country.

**Default HS / Commodity Code:** Optional Harmonized System (HS) tariff code applied to every export line item. Leave blank if your catalog has no single shared HS code.

> **Tip:** If you only ship domestically, leave the Customs tab at its defaults. It is never sent to DHL.

---

## How It Works

1. A customer adds shippable products to their cart and reaches the shipping step at checkout.
2. Once the cart has a shipping address, DHL Express builds a package summary: total weight and the largest length, width, and height across all shippable items.
3. The plugin requests rates from the DHL MyDHL `/rates` API using your credentials, the origin and destination, and the package details.
4. Each DHL service becomes a shipping option at checkout, filtered to your selected service codes and priced in your store currency, with your handling cost and tax profile applied.
5. After the order is placed, the order in the admin shows a **Create Label** button when the order used DHL Express and is in an allowed status. Clicking it calls the DHL `/shipments` API with the product the customer was quoted. The waybill and tracking number are saved to the order.

---

## Display Conditions

**DHL Express rates appear at checkout when:**

- The plugin is enabled in **J2Commerce -> Setup -> Shipping Methods** and published under **System -> Manage -> Plugins**.
- API Key, API Secret, and Account Number are all filled in.
- Origin Country and Origin City are configured.
- The customer has entered or selected a shipping address.
- The destination falls inside the configured **Geo Zone**, if one is set.
- The cart contains at least one shippable item with a weight greater than zero.
- DHL returns at least one service matching your **Service Codes** and **Network Type**.

> **Note:** Package weight and dimensions come from your product variants. If all shippable items in a cart have zero weight, DHL Express skips rating for that order.

**The Create Label button appears when:**

- The order was placed using DHL Express as its shipping method.
- The order's status is one of the **Allowed Order Statuses**, or that field is empty.
- No tracking number has been saved to the order yet.

---

## Tips

- **Test in sandbox first.** Leave **Test Mode** set to **Yes** while you configure the plugin.
- **Set weights on every shippable product.** DHL Express cannot rate a cart with zero total weight.
- **Keep a fallback shipping method active.** If DHL credentials expire or the API is unavailable, customers with no other option cannot check out.
- **Match your Unit of Measurement to your DHL account.** A mismatch can produce rates that look wrong.
- **Review Allowed Order Statuses before going live.** Restrict it to confirmed or paid statuses to avoid being billed for labels on unpaid orders.

---

## Troubleshooting

### No DHL rates appear at checkout

**Cause:** Missing or incorrect API credentials, no product weight, an unconfigured origin, or a destination outside the configured Geo Zone.

1. Confirm the plugin is enabled in **J2Commerce -> Setup -> Shipping Methods** and published under **System -> Manage -> Plugins**.
2. Open the **DHL Credentials** tab and verify the **API Key**, **API Secret**, and **Account Number** were issued together.
3. Open the **Origin & Geo Zone** tab and confirm **Origin Country** and **Origin City** are set.
4. Confirm the products in the cart have a weight set.
5. If a **Geo Zone** is configured, confirm the destination is included in it.
6. Enable **Debug Mode**, retry checkout, and check `administrator/logs/shipping_dhlexpress.php` for the DHL error message.

### Rates seem wrong or inconsistent with DHL's website

**Cause:** The store is in **Test Mode**, the **Unit of Measurement** does not match your DHL account, or a **Handling Cost** is added.

1. Set **Test Mode** to **No** for live pricing.
2. Check that **Unit of Measurement** under **Origin & Geo Zone** matches your DHL account.
3. Check the **Handling Cost** under **Display & Pricing**.
4. Confirm product weights and dimensions are accurate.

### Labels fail to generate

**Cause:** A label already exists for the order, required address fields are missing, or customs data is incomplete.

1. If the order already has a tracking number, clear it first to regenerate the label.
2. Confirm the order's shipping (or billing) address has a city, postal code, and country.
3. For international shipments, check the **Customs (International)** tab: set **Incoterm** and **Export Reason**, and add a **Default HS / Commodity Code** if DHL rejects missing commodity data.
4. Enable **Debug Mode** and check `administrator/logs/shipping_dhlexpress.php` for the field-level error.

### The Create Label button doesn't appear on an order

**Cause:** The order's shipping method was not DHL Express, its status is not in **Allowed Order Statuses**, or a tracking number already exists.

1. Confirm the order used **DHL Express Delivery**.
2. Open the **DHL Waybill / Label** tab and check **Allowed Order Statuses**.
3. Check whether the order already has a tracking number.

### Debug log grows very large

**Cause:** **Debug Mode** was left enabled on a busy production store.

Open the **Display & Pricing** tab and set **Debug Mode** to **No**.
