Skip to main content

DEA Compliance for Online Pharmacies: 2026 Guide

The Ryan Haight Act (21 U.S.C. 831) covers any site dispensing controlled substances into the US from April 13, 2009. Didit supplies patient identity, biometric and AML checks at $0.33 per full ID check and $0.20 per AML.

DEA Compliance for Online Pharmacies: 2026 Guide

Contents

In this guide

Jump to the part you need.

DEA compliance for online pharmacies comes down to three things: a valid prescription, a verified patient, and a record you can produce on request. The rules apply to a site that meets the statutory definition in 21 U.S.C. section 802(52): a person, entity or internet site that knowingly dispenses a controlled substance by means of the internet, including a site outside the US that ships into it. Non-controlled prescriptions sit outside it, and the rest of the definition needs reading against your own model. A Didit full ID check costs $0.33 and patient AML screening costs $0.20. The caveat: we support your compliance program, we do not replace your DEA registration, your EPCS application, your pharmacy system or your counsel.

Last updated: November 26, 2026. Prices checked against the live Didit price feed on November 26, 2026.

Summary

DEA compliance for online pharmacies at a glance
QuestionAnswer
Who is subjectAny person, entity or internet site that knowingly dispenses a controlled substance by means of the internet, including sites outside the US that sell into it (21 U.S.C. section 802(52)).
WhereUnited States federal law, the law of every state you dispense into, and your state board of pharmacy.
From whenThe Ryan Haight Online Pharmacy Consumer Protection Act of 2008 (Pub. L. 110-425) was signed on October 15, 2008 and took effect on April 13, 2009 with the DEA rule that implemented it.
Main instruments21 U.S.C. section 831, 21 CFR parts 1301, 1304, 1306 and 1311.
Didit full ID check$0.33 per completed check: ID document verification $0.15, passive liveness $0.10, face match 1:1 $0.05, device and IP analysis $0.03.
Didit AML screening$0.20 per check against 1,300+ sanctions, PEP and watchlist sources.
Cost to testSandbox testing is free and unlimited.

Start free in the sandbox at https://business.didit.me/ with no sales call. Developers can connect Didit to an AI assistant through the MCP server. Prices and plans are on https://didit.me/pricing/.

Who has to comply, where, and from when

The statute is 21 U.S.C. section 831. It uses the definition at 21 U.S.C. section 802(52): an online pharmacy is a person, entity or internet site, whether in the US or abroad, that knowingly delivers, distributes or dispenses a controlled substance by means of the internet. A company outside the US is in scope when it ships to a US address.

Three sets of rules apply. Federal: DEA registration under 21 U.S.C. section 823 and 21 CFR section 1301.13, prescription rules in 21 CFR part 1306, records in 21 CFR section 1304.04, and security in 21 CFR sections 1301.71 to 1301.76. State: a licence in every state you dispense into, that state's prescription monitoring programme, and its telehealth and e-prescribing laws. Contractual: payer and pharmacy benefit rules.

None of these asks the DEA to approve your software. They ask you to show, on inspection, that the prescription was valid, the patient was the patient, the prescriber was authorised, and your records are complete. Didit supports the identity and fraud checks in that chain. The pharmacy, the prescriber, the EPCS provider and your counsel keep the legal obligations.

Applicability dates

When each obligation starts and who it binds
InstrumentWho it bindsWhereFrom when
Ryan Haight Act, Pub. L. 110-425, 21 U.S.C. section 831Online pharmacies, prescribers and sites dispensing controlled substances by means of the internetUS federalSigned October 15, 2008; in force April 13, 2009
Registration, 21 U.S.C. section 823 and 21 CFR section 1301.13Every pharmacy handling controlled substancesUS federalIn force since May 1, 1971; renewal cycle in 21 CFR section 1301.13
Prescription validity and corresponding responsibility, 21 CFR section 1306.04(a)Prescribers and dispensing pharmacistsUS federalIn force since May 1, 1971
Electronic prescriptions for controlled substances, 21 CFR part 1311Prescription and pharmacy applications, and the practitioners who signUS federalPublished March 31, 2010; effective June 1, 2010
Medicare Part D electronic prescribing, SUPPORT Act (Pub. L. 115-271), 42 CFR section 423.160Part D prescribers and dispensing pharmaciesUS, Medicare Part DJanuary 1, 2021
State electronic prescribing mandates, for example New York I-STOPPrescribers and pharmacies in that stateStateNew York from March 2016; check each state board
Recordkeeping, 21 CFR section 1304.04RegistrantsUS federalAt least two years from the date of entry
Telemedicine flexibilities, successive temporary DEA rulesPrescribers treating patients remotelyUS federalThe January 2025 rule extended them through December 31, 2025; confirm the 2026 position at the Federal Register

What the rules require and what Didit does about each one

Obligations next to Didit capability, with the limits stated
Obligation and sourceWhat the rule asks forDidit product and published priceWhat Didit does not do
A valid prescription for a legitimate medical purpose, 21 CFR section 1306.04(a)Evidence that the prescription was clinically justified and reviewedCustom Questionnaires at $0.10 per check. Use them to collect additional answers in your workflow.We do not decide whether a prescription is clinically appropriate. That stays with the prescriber and the pharmacist.
Practitioner relationship under the Ryan Haight Act, 21 U.S.C. section 831, with the telemedicine route at 21 U.S.C. section 802(54)Proof that the prescriber evaluated the patient, in person or through an allowed telemedicine routeID Verification $0.15, Passive Liveness $0.10 and Face Match 1:1 $0.05, plus Reusable KYC at no charge for returning patientsWe do not conduct or attest the medical evaluation, and we do not certify that a telemedicine route is lawful for a state.
Dispensing to the right patientConfidence that the person ordering is the patient named on the prescriptionFull ID check $0.33, including Device and IP Analysis $0.03 for VPN, Tor, duplicated device and location-mismatch signals; Face Search 1:N at $0.05 per searchWe do not know your patient roster. Duplicate detection is a signal for your policy, not a determination.
Prescriber authority, 21 CFR section 1306.03A practitioner registered with the DEA and licensed to prescribe in the relevant jurisdictionDatabase Validation, priced by country and service in the live price feed. AML Screening at $0.20 checks the prescriber against 1,300+ lists.We do not query the DEA registrant database or the NPI registry. Verify the prescriber's registration and licence with the DEA and the state board yourself.
EPCS two-factor authentication, 21 CFR section 1311.105, and the biometric bar at section 1311.116Two of three factors on the prescriber's signing credential, with a compliant biometric where a biometric is usedBiometric Authentication at $0.10 per authentication, with Face Match 1:1 at $0.05 and active liveness at $0.15 available in the same session. The first 50,000 authentication active users each month are free.We are not an EPCS application provider, we do not issue DEA signing credentials, and we do not perform the third-party audit or certification that 21 CFR part 1311 places on the application provider.
Audit trail and record retention, 21 CFR section 1311.210 and 21 CFR section 1304.04An internal audit trail that shows who did what, and records kept at least two yearsEvery session keeps its decision payload, warnings and an audit log. Log retention is 30 days on Free, one year on Growth, three years on Scale with export, and whatever the contract sets on Enterprise. Data retention is configurable from one month to ten years.Our audit log covers verification sessions. It is not your dispensing record and it does not replace your pharmacy system's audit trail.
Red flag review and diversion monitoringPatterns that suggest a prescription is being sought for other than a medical purposeAML Screening $0.20 per check, Ongoing AML Monitoring at $0.07 per person a year, Transaction Monitoring at $0.001 per transaction beyond your plan allowance, and 200+ fraud signals on every sessionWe surface signals. A pharmacist still has to resolve each red flag, and that resolution is the record an inspector will read.
Protecting patient dataControls over identity and biometric data you holdSOC 2 Type 2, ISO/IEC 27001:2022, GDPR compliance, iBeta Level 1 and Level 2 under ISO 30107-3, EU data residency by default, configurable retention down to one monthAsk us directly about a HIPAA business associate agreement before you send patient data. Do not assume one is in place.

EPCS two-factor authentication and the audit trail

21 CFR part 1311 applies when a controlled substance prescription moves electronically. Two sections carry the question buyers ask us most often: section 1311.105 for two-factor authentication and section 1311.116 for what a biometric has to do to count as one of the two factors.

The two-factor requirement sits on the prescriber's signing credential, not on the patient. Section 1311.105 asks for two of three factors: something you know, something you have, and something you are. Where the second factor is a biometric, section 1311.116 sets the technical bar, including a one-to-one comparison of the live sample against an enrolled template rather than a search across a population.

A pharmacy capturing a patient's face before releasing a Schedule II order is doing patient identity verification. That is a different control from EPCS two-factor authentication of the prescriber. Both matter, and an inspector will ask about them separately.

A user face being scanned during the liveness and face match step of a verification session
A patient selfie captured for passive liveness and a 1:1 face match against the document portrait, part of the $0.33 full ID check.

The practitioner signs, but the software that issues and retains the signing credential is the application provider, and part 1311 puts audit and certification duties on that provider (section 1311.300). We are not an EPCS application provider. We do not issue DEA signing credentials. What we supply is identity proofing and biometric checks you can put in front of a credential: a full ID check at $0.33, and Biometric Authentication at $0.10 per authentication can be used for returning users.

Create a session with the documented call:

curl -X POST 'https://verification.didit.me/v3/session/' -H 'x-api-key: YOUR_API_KEY' -H 'Content-Type: application/json' -d '{"workflow_id": "YOUR_WORKFLOW_ID", "vendor_data": "patient-8291", "callback": "https://your-pharmacy.example/post-kyc"}'

The response carries session.url. Send the user there or mount the SDK, then read the decision:

curl 'https://verification.didit.me/v3/session/SESSION_ID/decision/' -H 'x-api-key: YOUR_API_KEY'

The decision payload carries database_validations[], aml_screenings[] and ip_analyses[]. You can subscribe to session.status.updated instead of polling. Each step is a feature on the workflow.

A session overview in the Didit Business Console listing the warnings raised during a verification
The session overview in the Didit Business Console. Warnings, step results and the decision stay attached to the session for your audit log retention period.

How patient identity is verified for telehealth

The prescriber conducts the evaluation. On the pharmacy side, prove the person at the other end is the patient named on the prescription and keep evidence. One session can run several steps:

  • ID document. $0.15. Government documents from 220+ countries and 14,000+ document types, with authenticity checks on the document itself.
  • Passive liveness. $0.10. Confirms a live person is present rather than a photo, a replay or a mask. Our liveness detection is iBeta Level 1 and Level 2 certified under ISO 30107-3.
  • Face match 1:1. $0.05. Compares the live capture to the portrait on the document.
  • Device and IP analysis. $0.03. Flags VPN, proxy, Tor, datacenter IPs, duplicated devices and a location mismatch with the document's issuing country.
  • Non-document lookup, optional. Pricing varies by country and service; check the current price for the method you plan to use. The patient types a national ID number and a few details, checked against the authoritative source for that country. Read the per-country source column before you enable a country, because in some markets the source is a credit bureau or utility file rather than a state register.
  • Returning patients. Biometric Authentication at $0.10 per authentication can be used for returning users. Reusable KYC is free.

The decision payload is per session. It lists every check that ran and every warning raised, and it is what you attach to the file when a regulator asks how a Schedule II order was verified. Didit serves 4,000+ companies.

Worked cost example

Take a telehealth pharmacy with 2,000 new controlled-substance patients a month and 1,500 returning patients who re-authenticate. Every new patient runs a full ID check, AML screening and a US phone verification. Figures use published list prices from the live price feed on November 26, 2026.

Per new patient at list price:

  • Full ID check: $0.15 + $0.10 + $0.05 + $0.03 = $0.33
  • AML screening: $0.20
  • US SMS code: $0.0473 (carrier price plus the $0.02 Didit fee)
  • Total per new patient: $0.33 + $0.20 + $0.0473 = $0.5773

Usage a month and a year, before plan fees and credits:

  • New patients: 2,000 x $0.5773 = $1,154.60 a month
  • Returning patient authentication: 1,500 x $0.10 = $150.00 a month
  • Usage a month: $1,154.60 + $150.00 = $1,304.60
  • Usage a year: $1,304.60 x 12 = $15,655.20
  • Ongoing AML monitoring: 2,000 x $0.07 = $140.00 a year

Those are usage figures, not cash. On Free the plan fee is $0.00 and the credit is $10.00 a month for organizations that sign up with a work email, so cash is $1,304.60 - $10.00 = $1,294.60 a month. Over a year that is $1,294.60 x 12 = $15,535.20, plus the $140.00 of monitoring, so $15,675.20. Anything the credit does not cover comes from a prepaid top-up.

On Scale, Didit fees are 10% lower; carrier charges pass through at cost.

  • Full ID check $0.297, AML $0.18, US SMS $0.0453 (carrier $0.0273 plus the $0.018 fee)
  • Per new patient: $0.297 + $0.18 + $0.0453 = $0.5223
  • New patients: 2,000 x $0.5223 = $1,044.60 a month
  • Returning patient authentication: 1,500 x $0.09 = $135.00 a month
  • Usage a month: $1,044.60 + $135.00 = $1,179.60
  • Usage a year: $1,179.60 x 12 = $14,155.20
  • Ongoing AML monitoring: 2,000 x $0.063 = $126.00 a year

Here the plan fee and the credit change the cash figure. Scale costs $299.00 a month and carries $350.00 of credit a month, so the first $350.00 of usage is already paid for: cash is $299.00 + ($1,179.60 - $350.00) = $299.00 + $829.60 = $1,128.60 a month. Over a year that is $1,128.60 x 12 = $13,543.20, plus the $126.00 of monitoring, so $13,669.20.

Not included: DEA registration fees, state licences, your pharmacy system, your EPCS application and the staff who resolve red flags. Estimate your mix on the pricing page.

Exceptions and open questions

Non-controlled prescriptions are outside the Ryan Haight Act. The Act governs controlled substances dispensed by means of the internet. Your ordinary prescription flow has its own state rules.

The telemedicine position moves. DEA extended COVID-19 flexibilities by temporary rules, and the January 2025 rule ran through December 31, 2025. A proposed special registration rule was published alongside it and, as far as we can verify, has not been finalised. Current temporary and permanent telemedicine rules must be checked before relying on this summary. Confirm at the Federal Register and the DEA Diversion Control Division.

In-person evaluation is not the only route. 21 U.S.C. section 802(54) covers several situations, including treatment while the patient is physically at a DEA-registered hospital or clinic. Whether your model fits is a legal question for counsel.

States are often stricter. New York mandated electronic prescribing for controlled substances from March 2016, and other states have their own dates, monitoring requirements and telehealth statutes. A workflow that satisfies 21 CFR part 1311 may still fail a state board rule.

What we cannot answer. We are not your DEA registration, not an EPCS application provider, do not query the DEA registrant database or NPI registry, and do not give legal advice. Ask about a HIPAA business associate agreement before sending patient data.

An AML screening result in the Didit Business Console showing hits and scores for a screened person
An AML screening result attached to a session. Each hit carries a match score and a risk score, so a reviewer can clear a false positive without reopening the whole file.

Implementation checklist

  1. Map which prescriptions are controlled, by schedule, and which states you dispense into.
  2. Write the identity evidence you require for new patients, returning patients, prescriber onboarding, address changes and high-value orders.
  3. Ask counsel to confirm the current telemedicine route and each state's e-prescribing and monitoring rules.
  4. Build the workflow: ID Verification, Passive Liveness, Face Match 1:1, AML Screening, Phone Verification, then your own prescriber check.
  5. Set AML and liveness thresholds. Decide what a device or IP warning does: decline, extra step or manual review.
  6. Wire POST /v3/session/ and GET /v3/session/{sessionId}/decision/, or subscribe to session.status.updated. Store the decision payload against the order.
  7. Choose the plan with the audit log retention you need: 30 days Free, 1 year Growth, 3 years with export on Scale, custom on Enterprise.
  8. Sandbox testing is free and unlimited, so test before you turn on live checks.
  9. Keep prescriber verification outside Didit: DEA registration, state licence and the credential that satisfies 21 CFR section 1311.105 inside your EPCS application.
  10. Review the telemedicine rule status and state mandates quarterly.

If you are moving off another vendor, the migration path is on https://didit.me/switch/. For AML specifically, the product page is https://didit.me/products/aml-screening/.

Sources

Next step: create a free sandbox organization at https://business.didit.me/, run a test session against your own patient flow, and read the decision payload before you talk to anyone. No sales call is required, and the plan and unit prices you will pay are published at https://didit.me/pricing/.

Try it

Try this in the sandbox

Run the check this guide describes, free.

ID Verification

The product this post is about, taken from its topic. Run it free in the sandbox.

$0.15 per checkStart free

Author

Alberto Rosas

Co-founder and CEO

Alberto Rosas

Alberto Rosas

Co-founder and CEO

About Didit

Questions

Frequently asked questions

Is there an open-source or pay-as-you-go API that handles EPCS two-factor requirements so I do not have to chase DEA audits?

There is no open-source package we would point you to for 21 CFR part 1311 end to end. The audit obligation sits with the application provider that issues and holds the prescriber's signing credential (21 CFR section 1311.300), not with a library you install. What is pay-as-you-go is the identity proofing and authentication that feed that credential: a full ID check at $0.33 and Biometric Authentication at $0.10 per authentication. Didit is not an EPCS application provider and does not certify part 1311 compliance.

How does a pharmacy capturing a pharmacist's or patient's biometric with an unalterable audit trail affect Schedule II electronic prescriptions?

Two separate controls get confused. EPCS two-factor authentication under 21 CFR section 1311.105 applies to the prescriber's signing credential, and where the second factor is a biometric, section 1311.116 sets the technical bar including a one-to-one comparison against an enrolled template. Capturing a patient's thumbprint or face at the pharmacy is patient identity verification, a different control. A verification session log covers the identity checks Didit ran, while the EPCS audit trail obligation under section 1311.210 attaches to the pharmacy application.

How is patient identity verified for telehealth?

The prescriber conducts the evaluation and the pharmacy proves the person receiving the drug is the patient on the prescription. One session can run an ID document check, passive liveness, a 1:1 face match and device and IP analysis for $0.33, with AML screening at $0.20 and phone verification if policy requires. Biometric Authentication at $0.10 per authentication can be used for returning users, and Reusable KYC is free.

What does the DEA require before an online pharmacy dispenses a Schedule II drug?

The pharmacy must hold a valid DEA registration, the prescription must be issued for a legitimate medical purpose by a practitioner acting in the usual course of professional practice under 21 CFR section 1306.04(a), and under the Ryan Haight Act the practitioner must generally have conducted at least one in-person medical evaluation, subject to the telemedicine routes at 21 U.S.C. section 802(54). The pharmacist also has a corresponding responsibility to resolve red flags before dispensing.

Is an in-person medical examination always required?

Not always. The Ryan Haight Act requires an in-person medical evaluation before a practitioner prescribes controlled substances by means of the internet, then lists situations where a telemedicine encounter satisfies the requirement, including treatment while the patient is physically present at a DEA-registered hospital or clinic. Current temporary and permanent telemedicine rules must be checked before relying on this summary.

How long must an online pharmacy keep records?

21 CFR section 1304.04 requires records kept for at least two years from the date of entry. Electronic prescription applications carry their own audit trail obligations under 21 CFR part 1311. Pick a Didit retention setting that matches the longest period you must support, up to ten years.

Can Didit verify the prescriber's DEA registration number?

No. Database Validation, priced by country and service in the live price feed, checks identity details against authoritative sources in 60+ live countries, and AML Screening at $0.20 checks the prescriber against 1,300+ sanctions, PEP and watchlist sources. Neither queries the DEA registrant database or the NPI registry. Verify DEA registration and the state licence directly with the DEA and the state board, and use Didit for the prescriber's own identity and screening checks.

Does Didit replace my pharmacy management system or my EPCS application?

No. Didit handles identity verification, biometric authentication, AML screening and transaction monitoring, and returns a decision payload you store against the order. Your pharmacy system still produces the dispensing record, and your EPCS application still holds the prescriber credential and the part 1311 audit trail. We sit in front of both.

How much does it cost per patient?

A full ID check is $0.33: ID document $0.15, passive liveness $0.10, face match 1:1 $0.05 and device and IP analysis $0.03. Patient AML screening is $0.20, ongoing AML monitoring is $0.07 per person a year, and Biometric Authentication is $0.10 per authentication with the first 50,000 authentication active users each month free. Growth takes 4% off every Didit price and Scale takes 10%.

Is there a free way to test this before we sign anything?

Yes. Sandbox testing is free and unlimited, and you can integrate without a sales call. The Free plan also includes $10 of credit a month for organizations that sign up with a work email, which buys about 30 full ID checks at $0.33 each. The self-serve plans are Free, Growth and Scale, and Enterprise contracts start at $15,000 a year.

Compliance built in

Audited, certified and attested.

We hold the certifications and build each country's rules into your flows, so you can launch anywhere without worrying. Security and Compliance center

  • Regulation encoded into your flows

    Tell us what you do and where. Didit lists the rules that apply to you, with sources, and builds the checks each country needs into one workflow.

  • Ready for AMLR

    Every requirement of the new EU anti-money laundering rules, from checking customers to human review, is already covered by a Didit check.

  • Tested in Spain's Treasury sandbox

    Spain's Treasury published its supervised sandbox report on Didit's NFC plus active liveness onboarding; SEPBLAC took part and valued the added measures positively.

  • Audited, not self-declared

    iBeta Level 1 and Level 2. Liveness tested under ISO/IEC 30107-3.

Compliance assistant

Your obligations · 3 regions

EU · AMLRCustomer due diligence, human reviewCovered
Illinois, Texas, ColoradoExplicit biometric consentCovered
Germany · Youth protectionVerified adults only (JMStV)Covered
Workflow checked. Every obligation is met
  • SOC 2 Type 2
  • ISO 27001
  • iBeta Level 1 and Level 2
  • EU regulator attestation
  • FSM youth protection
  • GDPR
  • EBA remote onboarding
  • MiCA compatible
  • FIDO Alliance member
  • AMLREU AML Regulation ready

Integration · Didit MCP

Run Didit from your own AI agent

Connect Didit to Claude, Cursor, VS Code or ChatGPT and just ask in plain words. Your agent can do anything you can do in the console, with the same permissions you have.

Add to ClaudeChatGPT
Didit Academy · Lesson 04 · Use Didit with MCP
  • Build workflowsDescribe the checks you need. The agent creates and publishes the flow.
  • Run investigationsAsk why a session was declined, review cases, search people and companies.
  • Change rulesCreate payment rules, test them on past data and switch them on.
  • Pull reportsAsk for numbers, exports or the audit log.

Verify your first user today.

Start free

Free sandbox. Credit applies to work-email sign-ups.