Alex Perez was set for a flyweight bout against Manel Kape at UFC on ESPN: Vera vs. Sandhagen in San Antonio on Saturday but pulled out of the fight over what he revealed to be a serious health issue.

Perez wrote on social media on Sunday he suffered a seizure while warming up for the fight.

CLICK HERE FOR MORE SPORTS COVERAGE ON FOXNEWS.COM

Alex Perez at UFC 277

Alex Perez warms up backstage during the UFC 277 event at American Airlines Center on July 30, 2022 in Dallas. (Mike Roach/Zuffa LLC)

"First and foremost, I want to thank everyone for all the support and concerns," his message on Instagram read. "I was doing my pre-fight warm up and had a seizure. I immediately received medical attention.

"My hydration, electrolytes, etc were all more than adequate. This has nothing to do with weight cut. It was one of the easiest cuts of my career. I will be undergoing further testing in the upcoming weeks to determine the cause. I would appreciate privacy. My (apologies) to my opponent and fans. Thank you to the UFC medical team for their help and support."

UFC FIGHTER HOLLY HOLM CALLS FOR AN END TO THE SEXUALIZATION OF CHILDREN

Alex Perez and Manel Kape

Alex Perez, left, and Manel Kape face off during the UFC Fight Night ceremonial weigh-in at AT&T Center on March 24, 2023 in San Antonio. (Josh Hedges/Zuffa LLC)

Perez was ranked No. 6 in the official UFC flyweight rankings with an overall record of 24-7.

The 31-year-old fighter last won in June 2020 with a technical knockout of Jussier Formiga. He then lost to Deiveson Figueiredo in November 2020 and then Alexandre Pantoja in July 2022.

He only lost four fights before getting to UFC.

Alex Perez in San Antonio

Alex Perez steps on the scale for the official weigh-ins at Westin San Antonio North for UFC Fight Night - Vera vs Sandhagen - Weigh-ins on March 24, 2023 in San Antonio. (Louis Grasse/PxImages/Icon Sportswire via Getty Images))

CLICK HERE TO GET THE FOX NEWS APP

It is unclear when Perez’s next fight will take place.