There must be a programmable way (using Solidity or whatever programming language) to convert custom built ERC-20 tokens (Smart contracts on the Ethereum blockchain) to WETH (Wrapped Ether) OR through the service of an interactive website that provide this feature. Any idea or help is welcome. Thanks.
You can convert it using uniswap. Erc20 smart tokens are compatible with weth it's just a wrapped eth but technically it's still eth. Uniswap does the conversion directly from tokens to weth even their pairing or liquidity is eth or usdt. But you just add some fees higher than normal one since it will convert it for you from eth to weth or usdt to weth.
I've always directing my trades to usdt so whichever liquidity they had is no problem at all on uniswap trading.