Pain medicines work in different ways to help relieve pain. Doctors and pharmacists can recommend different types of medication depending on the source of pain and other factors.

A person lying on a sofa with a leg cast and cute doggoShare on Pinterest
Cavan Images/Getty Images

Choosing the most appropriate medication requires matching the cause of pain with the best medication that targets it. Some people may experience side effects, but the severity can vary greatly.

While over-the-counter (OTC) pain medications are available, stronger ones — for example, opioids — require a doctor’s prescription and monitoring.

This article provides an overview of how pain medicines work.

Experts are still unsure how acetaminophen works to treat or relieve pain. One theory is that acetaminophen attaches itself to a variation of an enzyme (a type of protein) involved in pain known as cyclooxygenase-3 (COX-3).

However, researchers have yet to confirm this theory in humans.

If acetaminophen blocks COX-3, it will stop the pathway that leads to prostaglandin production in the central nervous system. Prostaglandins are natural chemicals the body produces that have associations with pain and inflammation. Therefore, blocking COX-3 provides pain relief.

How long does it take to work?

How long it takes acetaminophen to work depends on the form. The table below details the different forms of the medication and how long they can take to start working.

Form of acetaminophenOnset of action
Intravenous (via injection)5–10 minutes
Oral (tablet, capsule, syrup, solution, suspension)Less than 1 hour
Rectal (suppository)35–45 minutes

Possible side effects

Acetaminophen is a safe medication that people can find over the counter.

Possible side effects include:

  • rash
  • allergic reaction
  • disturbance in blood cell count — for example, low red blood cell count
  • electrolyte imbalances — for example, low sodium levels in the blood
  • kidney failure

Different side effects may occur with intravenous (IV) acetaminophen injections. These include:

  • nausea
  • vomiting
  • abdominal pain

Nonsteroidal anti-inflammatory drugs (NSAIDs) block cyclooxygenase, which is an enzyme involved in producing prostaglandins. By blocking their production and release in the body, NSAIDs treat pain resulting from inflammation.

How long do they take to work?

NSAIDs come in various forms. These include oral capsules, tablets, suspensions, rectal suppositories, and IV injections.

Diclofenac is a specific type of NSAID in a topical form — meaning people apply it to the skin. This type can take 1–2 days to work.

IV injections of ibuprofen, for example, start working within seconds.

Oral forms will take the longest to work because they must travel through the digestive tract before being absorbed into the blood. Pain relief from oral ibuprofen can take about 30–60 minutes.

Possible side effects

OTC and prescription NSAIDs can cause side effects. These may occur in different body systems, such as the cardiovascular, digestive, and kidney systems. The possible side effects of NSAIDs are:

Some NSAIDs are only available through a prescription because their side effects can be more severe in certain populations. For example, doctors may not recommend NSAIDs to people with a history of ulcers, stomach bleeding, or heart attack.

Opioids act on receptors (another type of protein) that are found in the nervous system and are involved in pain. Primarily, opioids act on “mu receptors” and activate them. In doing so, the medication blocks pain signals from reaching the central nervous system.

How long do they take to work?

Like other pain medicines, how long it takes opioids to work depends on the form. IV morphine, for example, acts the fastest. Within 5–10 minutes, a person can feel pain relief. Intramuscular injections take a little longer, between 10 and 30 minutes.

Oral opioids may take about 30 minutes before they start working.

Fentanyl is available in different forms that all have different onsets of action. The intranasal form (which a doctor administers through the nose) starts working within 5–10 minutes. The nebulizer form (which a person inhales) starts working immediately.

Possible side effects

Opioids have many side effects, which can limit their use. They can affect different body systems. These side effects include:

  • feeling high
  • feeling very tired
  • constipation
  • nausea
  • vomiting
  • allergic reaction
  • slow heart rate
  • trouble breathing

Overdose is a serious side effect of opioids, as it can have life threatening consequences.

Gabapentin (Gralise) and pregabalin (Lyrica) are two antiseizure medications that doctors prescribe for nerve pain. They reduce the release of proteins known as excitatory neurotransmitters in the central nervous system and which are typically involved in nerve pain.

How long do they take to work?

Gabapentin and pregabalin take days or weeks to start working. Doctors will adjust doses after about a week. If the person does not experience significant pain relief, the doctor will then increase the dose and readjust after another week.

Antiseizure medications take longer to start working than opioids, NSAIDs, and acetaminophen.

Possible side effects

The most common side effects of pregabalin and gabapentin include:

  • dizziness
  • fluid buildup in the arms or legs
  • feeling tired

The following table lists the possible side effects of these two antiseizure drugs:

Side effects of pregabalinSide effects of gabapentin
headacheuncontrolled muscle movements
nauseaconfusion
weight gainsevere allergic reaction
feeling disorientedsuicidal thoughts or behaviors
blurry visiondepression
increased risk of suicidal thoughtsfever
bloatinginfection
mood changesStevens-Johnson syndrome
respiratory problemsmuscle disorder (rhabdomyolysis)

Antidepressants such as amitriptyline (Elavil) and duloxetine (Cymbalta) also help relieve nerve pain. They work by acting on neurotransmitters known as serotonin and noradrenaline. These neurotransmitters play a role in determining the intensity of pain a person feels.

Blocking the effect of these neurotransmitters can help to suppress certain pain pathways in the brain. Also, these medications can act on other proteins and neurotransmitters that play a role in pain sensation.

How long do they take to work?

Like antiseizure medications, antidepressant pain relievers take weeks to start working. Doctors suggest waiting at least 6–8 weeks before considering that the medication is not working.

Possible side effects

Typical side effects of antidepressant medications in treating pain include:

The following table lists some of the more specific side effects of duloxetine and amitriptyline.

Side effects of duloxetineSide effects of amitriptyline
feeling tiredchanges in mental status
stomach painirregular heartbeat
increased blood pressuredizziness
changes in body weightincreased sweating
reduced appetiteurinary retention
muscle pain or crampsshaking
decreased libidoweight gain

Local anesthetics are OTC products that people can apply to their skin. For example, an athlete may rub a local anesthetic on the skin near a sore muscle.

Lidocaine (Xylocaine) and capsaicin (Zostrix) creams are some examples of this medication type. They work by binding to sodium channels to block nerve cells in the body from sending pain signals to the brain.

How long do they take to work?

Local anesthetics such as these can act quickly to relieve muscle pain. This is because they are vasoactive, which means that the skin quickly absorbs them into the bloodstream.

Possible side effects

Lidocaine may cause local side effects. These include:

  • pain at the application area
  • itchiness
  • redness
  • skin irritation

Capsaicin may also cause itchiness, a burning sensation on the skin, and rash.

Below are some common questions and answers on this topic:

Which one do doctors usually prescribe?

A 2018 study listed the top 200 prescribed drugs in the United States. The top pain medicine was a drug combination of acetaminophen with hydrocodone, which is an opioid.

Other top pain relievers that doctors prescribe in the U.S. include the NSAIDs ibuprofen and meloxicam and the opioid oxycodone.

Which one is the strongest?

When a person uses them appropriately, opioids can provide the strongest pain relief. However, these pain medicines have the most side effects and risks. People can develop a tolerance and an addiction to opioids.

Doctors must follow up with people taking opioids for pain. They will monitor the response to pain and any potential for diversion.

What if pain medications are not working for someone?

When a person feels that a pain medication is not working as it should, it can be tempting to increase the dose. However, people should avoid doing this. Instead, they should only take medications as the label or their doctor advises.

If a medication is not working as expected or side effects become hard to manage, a person should speak with their healthcare professional.

Doctors and pharmacists can choose among different medications to treat pain.

The most effective pain medicines are those that act on the source of the pain. While opioids are the strongest pain relievers, an NSAID may be safer and more appropriate for pain resulting from inflammation.

Seeking medical attention when side effects become difficult to cope with or when pain medications are not working as they should is important.