Could be a good idea when the P/E ratio of the market is much lower than it is now.
One advantage of leveraged investing is that your interest payments are tax deductible (at least in Canada).
I would consider it during a major market crash.
Emphasis added. If you are going to leverage, do it AFTER the market has gone down 20%+. To do it while the market is consistently hitting all time highs is asking for trouble. You need a margin of safety so that you don't get a margin call. The market has gone down 50% twice in the past 15 years, keep that in mind.
That being said, the idea is to be able to pay as little interest as possible, and have the lowest margin requirements as possible. As posted by Velociraptor, Interactive Brokers is the best for margin rates of 1.7% or less. They also give you the option of portfolio margin if your account is $100k+. Normal margin on stocks is 50%. However, portfolio margin can be as little as 15%-20%. That means on a $100k account they might let it get down to $15-20k before they'll force you to sell.
Even better, is to buy index futures. You can get the e-mini S&P 500 index contract for $4,500 in margin from Interactive Brokers, pay no interest, and control $108k worth of stock at the current price (the contract is worth $50 x whatever the index is trading at, which today is 2174). So if your account is only $54k you can buy 1 contract and effectively be at 2x leverage.
The profit/loss of the contract is $50 per point. So if today it's selling for 2174, and it goes down to 2164 tomorrow, you'll lose $500 and your account will be worth $53,500. If the index goes down 50%, that's 1,087 points x $50 = $54,350 LOSS. They'll force you to sell when your account gets down to $4,500 so that's all you'll be left with from your original account.
This is why you should wait for a market crash. If it's already gone down 20% then the index will be at $1,739. If it went down 50% total, then it would only be the difference of 1,739-1,087 = 652 points. 652 x $50 = $32,600. $54,000 - $32,600 = $21,400 your account would be worth. $21,400 is more than the $4,500 margin requirement so they won't force you to sell.