WASHINGTON — Representative Darrell Issa, whose hard-edge partisan attacks on President Barack Obama began softening as his district trended toward the Democrats, said on Wednesday that he would not seek re-election — the latest and one of the most prominent Republican retirements in the face of a potential Democratic wave.

Mr. Issa, 64, who has represented an idyllic stretch of Southern California coast since 2001, won re-election in 2016 by just 1,600 votes out or more than 300,000 cast, while Hillary Clinton carried it by more than seven percentage points.

Mr. Issa had indicated that he was preparing to defend the seat, despite agreement by outside analysts and campaign operatives in both parties that it would have been one of the most competitive races in the country.