Question: I have noticed by doing some tests that when I publish the same contract on different networks, the address is the same. Then, the "Etherscan" of each network show a link to **blockscan.com** where it show all the EVM networks with the same address.

But I can't find the pattern of how it happens...

How could deploy a contract in several EVM networks with the certainty that all will have the same address?

Answer: 
A full answer to this question should detail the difference between `CREATE`, `CREATE2` opcodes, which are the two opcodes in the EVM for creating new contracts; it should be possible to do this using either as long as for `CREATE` you use the same keypair across all chains, and have the same nonce on all chains. [This](https://hackernoon.com/using-ethereums-create2-nw2137q7) article also details how to use `CREATE2` for the same task (provided initcode is consistent across all chains), which should be easier, all things considered. I'm going to gloss over that all because of CREATE3, though.

There has been some work recently nicknamed CREATE3. This isn't an actual opcode in the EVM ([yet](https://github.com/ethereum/EIPs/pull/3171)), but rather some work done to make contracts which are themselves contract factories which make it a bit easier to deterministically generate addresses. The first implementation I'm aware of is 0xsequence's [here](https://github.com/0xsequence/create3), though Rari also ships an implementation in [Solmate](https://github.com/Rari-Capital/solmate/blob/main/src/utils/CREATE3.sol).

There is a README in 0xsequence's repo explaining how to use the contract. The basic uptake would be that you could import this library, and as long as the contract bytecode is identical across all chains, just using the same salt in the `create3` function (or `deploy` in Solmate) should ensure that the address of all deployments is identical.
**Simple answer:** Create a new clean wallet, and use its private key to deploy the contract.

This will work because;

```
contractAddress = keccak256(userAddress, nonce);
// NOTE: nonce is the number of transactions done by userAddress.

```

Becasue your wallet is new, and hasn't done **any** previous transactions, your nonce will be zero.