A Ukip county councillor could be removed from the party after admitting to sharing offensive material about Muslims on his Facebook page.
Eric Kitson will quit the Worcestershire County Council seat he won less than two weeks ago following the incident.
The 59-year-old, who represented Stourport-on-Severn, has denied being a racist and claims he shared cartoons and jokes to show how "disgusting" they were.
He has since apologised and said it was "stupid" for him to share the messages, which were posted last year on his Facebook.
Bill Etheridge, the Ukip chairman for Dudley and Halesowen, said an internal investigation had been launched by the party and officials were considering Mr Kitson's membership of the party.
Mr Etheridge said: "Ukip does not condone hate, racism or prejudice. We totally condemn those things because it's not what the party is about. In fact it is the total opposite of what the party is about."
He said Mr Kitson's decision to resign was right under the circumstances.
"An investigation is taking place internally into the events and part of that investigation will consider his ongoing membership of the party.
"The party rules state that extreme views are not compatible so senior level head office members of the party will look at the facts of what has happened here and make their decision."
Mr Kitson has since closed his Facebook page.
He received 1,385 votes to take the Wyre Forest seat on May 2, beating rivals from the three mainstream political groups.Suggest a correction