A police officer has saved three people from drowning in Victoria's Port Phillip Bay, near Melbourne.

A 17-year-old girl got into difficulty about 250 metres off the shore at Frankston just after 10:30pm last night.

Two men went in to help her but also started to struggle.

The policeman swam out and got the trio to link arms and swim back to shore together.

The girl lost consciousness and stopped breathing during the rescue.

The officer resuscitated her in the water and she was later taken to hospital.