But caution about the vote results may prove warranted. Most investors were caught off guard in the past two general elections in 2004 and 2009 as opinion polls got it badly wrong.
Now some precautionary moves are being made. Customers say at least four brokerages have raised margin requirements due to concern there could be intense volatility after election results are unveiled on May 16.
The stock market regulator has asked exchanges to test their trading systems, according to an agency official, especially new mechanisms put in place last year to deal with market volatility. The Securities and Exchange Board of India (Sebi) did not reply to a written request for comment.
A surprise could knock both shares and the rupee. The gains stem from the assumption the BJP and its National Democratic Alliance (NDA) will win a majority, or near it, making Modi Indias prime minister.
From September 13 the day the BJP nominated Modi as its prime ministerial candidate through Friday, the National Stock Exchange, Indias biggest bourse, surged 17%, compared with only a 4% gain for the MSCI Asia-Pacific index excluding Japan.
On Friday, the NSE index rose as much as 3.2%, hitting a record high of 6,871.35.
Should BJP do poorly in the vote and Modi not become prime minister, some analysts predict shares could plunge 8-10% in one day, and up to 20% in the aftermath.
That would roughly match what happened in 2004, when investors were shocked that the BJP didnt win the election. The NSE index fell 12.2% in one day, and 19% over two.
Ritu Jain, managing director of investment bank Eos Capital Advisors in Mumbai, said the recent rally in Indian shares has been largely in anticipation of NDA coming to power with a majority or near to majority. In the event of NDA not coming to power, markets can correct byabout 15% or a little more.
The BJP has long been seen by markets as being more investor-friendly than the Congress party, spurring hopes Modi will revive an economy growing at its slowest pace in a decade. The hopes have sent sectors such as infrastructure and banks sharply higher.
Foreign investors have also bought in heavily, and now own a record 22% of companies listed on the NSE, according to Morgan Stanley data, after buying a net $20.1 billion last year and about $4.3 billion so far in 2014.
However, that high a level is raising concerns of possible destabilising foreign outflows that dent both the currency and shares.
A scenario of stock market volatility and huge volumes would mark the first major test for trading-system improvements made by Indian exchanges after a slew of fat finger incidents hurt confidence.
In a bid to prevent cases like a 2012 misplaced order that caused the NSE to plunge more than 15%, stock market regulator Sebi in September revised rules for circuit breakers. These allow for a more measured and more flexible response to sudden market movements.
An official of Sebi told Reuters last week that it asked exchanges to conduct stress tests to simulate a surge in trading volumes and volatility, including circuit breakers. We need to ensure that the pay-in and pay-out obligations are met in such an event, and that the exchanges can handle a sudden surge in volumes, said the official, who declined to be identified.
A spokeswoman for NSE declined to comment. A spokesman for BSE, the oldest exchange, said I am not aware about any special communication from Sebi. I will check on that. But all systems are checked before market hours.