Dilaudid, also known as hydromorphone, is a potent opioid analgesic used to treat severe pain when other medications have proven ineffective. It works by binding to specific receptors in the brain and spinal cord, changing how the body perceives and responds to pain stimuli.