Hospital pharmacies are pharmacies usually found within the premises of a hospital. Hospital pharmacies usually stock a larger range of medications, including more specialized and investigational medications (medicines that are being studied, but have not yet been approved), than would be feasible in the community setting.
Hospital pharmacies typically provide medications for the hospitalized patients only, and are not retail establishments and therefore typically do not provide prescription service to the public. Some hospitals do have retail pharmacies within them (see illustration), which provide over-the-counter as well as prescription medications to the public, but these are not the actual hospital pharmacy. Hospital pharmacies may provide a huge quantity of medications per day which is allocated to the wards and to intensive care units according to a patient's medication schedule.
Larger hospitals may use automated transport systems to aid in the efficient distribution of medications. Hospital pharmacists and trained pharmacy technicians compound sterile products for patients such as total parenteral nutrition (TPN) and other medications given intravenously such as neonatal antibiotics and chemotherapy. This is a complex process that requires specialized training of personnel, quality assurance of products, and appropriate facilities. Some hospital pharmacies have decided to outsource high-risk preparations and some other compounding functions to companies that specialize in compounding.