How to set custom provider?

How can I connect set the provider for a local blockchain im running on my computer.

I’m running hardhat (mainnet forked) and need to build a dapp for my contract