The musician, who was there to take part in The Xtra Factor, ran onto the stage during John & Edward's performance of 'Under Pressure' with a pineapple on his head. He slapped his bottom before running off again.
The twins continued with their song, and Louis Walsh later praised them for being professional and carrying on.
Writing on his Twitter page, Harris said: "Was just thrown out of x factor for jumping onstage during Jedward with a pineapple on my head."
Earlier today, Harris had posted a photograph of a pineapple with the caption "IMPORTANT" on the site.
The X Factor continues tomorrow at 8pm on ITV1.