Police said the victim, 52, was left with burns down her back after the terrifying incident at The Golden Lion pub in Jay’s Close.
The attack took place as the woman attempted to leave the pub between 9.30pm and 10pm on Saturday.
The substance gave her a burning sensation on her skin and caused her hair to matt, Hampshire Police said.
She did not require any medical treatment following the incident.
Police said the substance is not believed to be acid.
Two men, aged 48 and 53, both from Basingstoke, have been arrested on suspicion of attempted grievous bodily harm with intent and released on bail until May 10.
A Hampshire police spokesperson said: “There was a band playing in the pub at the time of the incident and it was very crowded.
“Were you there? The woman was wearing a leopard print top. Did you see her, or did you witness the incident? Did you take any photos or video footage while you were there? You may have caught the incident on your camera.
“The woman has been left extremely distressed by what happened to her. She has suffered reddening to her skin, blisters, and had to have most of her hair cut off due to the matting.”
Anyone with information about the incident is urged to call 101 and quote the 44240061292, or visit the Hampshire Constabulary website.