Police said some people attacked the BSP leader's car while he was electioneering for the ensuing polls at Nirmana village in the district.
Rana escaped unhurt. They said a case has been registered against 17 people in this connection.
Rana is the sitting MP from Muzaffarnagar and had filed his nomination from the seat on March 21.
The constituency will go to polls on April 10.