The present invention relates to a pharmaceutical composition in a container, wherein the container comprises cycloolefin polymer in its main contact surface that is in contact with the pharmaceutical composition, and wherein the pharmaceutical composition comprises a solution of fentanyl or of a pharmaceutically acceptable salt thereof in a solvent; the present invention further relates to a pharmaceutical composition for use in a method for treating pain; and to a drug delivery device containing the pharmaceutical composition.