├── .gitignore ├── FAQs.js ├── README.md ├── about.js ├── components ├── DarkMode.js ├── Form.js ├── HomePage.js ├── Layout.js └── MultiCards.js ├── context └── CountryContext.js ├── next.config.js ├── package.json ├── pages ├── _app.js ├── _document.js ├── guides │ ├── [slug].js │ └── index.js └── index.js ├── pnpm-lock.yaml ├── posthog.js ├── public ├── favicon │ ├── android-chrome-192x192.png │ ├── android-chrome-512x512.png │ ├── apple-touch-icon.png │ ├── favicon-16x16.png │ ├── favicon-32x32.png │ ├── favicon.ico │ ├── mstile-144x144.png │ ├── mstile-150x150.png │ ├── mstile-310x150.png │ ├── mstile-310x310.png │ ├── mstile-70x70.png │ ├── safari-pinned-tab.svg │ └── site.webmanifest ├── icons │ ├── double-tick.svg │ ├── icon-sq.svg │ ├── icon.svg │ ├── moon.png │ └── sun.png ├── manifest.json ├── meta-image-01.png ├── meta-image-02.png └── meta-image-03.png ├── screenshot-iphonex.png ├── screenshot.png ├── service-worker.js ├── styles └── global.css └── utils └── graphcms.js /.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | out 3 | 4 | .next 5 | .netlify 6 | .DS_Store 7 | .env.local -------------------------------------------------------------------------------- /FAQs.js: -------------------------------------------------------------------------------- 1 | import Link from 'next/link'; 2 | 3 | export const faqs = [ 4 | { 5 | q: <>How to WhatsApp without saving number?, 6 | a:
    7 | To WhatsApp without saving the number, follow these steps 8 |
  1. Open this tool
  2. 9 |
  3. Enter the recipient's contact number
  4. 10 |
  5. Tap "Open WhatsApp Chat" button
  6. 11 |
  7. Send WhatsApp as you normally do
  8. 12 |
13 | }, 14 | { 15 | q: <>How to make a call on WhatsApp without saving contact?, 16 | a: <> 17 |

Using this tool, you will be able to open WhatsApp chat window without saving number. You will be able to call the recipient from WA chat screen.

18 |
    19 | Follow these steps to call unknown number - 20 |
  1. Open this tool
  2. 21 |
  3. Enter the recipient's contact number
  4. 22 |
  5. Tap "Open WhatsApp Chat" button
  6. 23 |
  7. Call on WhatsApp as you normally do
  8. 24 |
25 | 26 | }, 27 | { 28 | q: <>What if this page saves my contacts?, 29 | a: <> 30 |

Thanks for asking. While there is no perfect way for any creator to assure their users that their service is 100% secure, I will try my best to answer your concern..

31 |

No, this tool does not save any personal data.

32 |

The only thing that the web app collects is analytics data (page visits, clicks) via Google Analytics and PostHog. Since contact number is not appended to URL before redirecting, analytics wouldn't collect number with url.So no personally identifiable, private data is shared or saved.

33 | 34 |

How do you assure your user that you don't save contacts?

35 |

Again, I wish there was a way I could give full assurance that I don't collect private data. Except for checking the web app security by yourself, every time before entering the contact number, you will have to take my word on this and trust me.

36 |

As a step towards being open, I have open-sourced code on github.

37 |

But then, the code deployed on the website can be something else. You will either have to trust this web app (or any website on the internet for this matter) or build yourself from scratch.

38 |

At last, I can hire a cybersecurity agency to audit the website, but then you will have to trust the agency :D

39 | 40 | }, 41 | { 42 | q: <>How does this tool work?, 43 | a: <> 44 |

WhatsApp has an unpopular way to open chat conversation with unsaved contact number - wa.me link.

45 |

You can create a special wa.me link (https://wa.me/COUNTRYCODE+PHONE) and open it in browser.

46 |

WhatsApp Anyone use the same mechanism, but while offering you added convenience! It's simple, secure & installable website.

47 | 48 | }, 49 | { 50 | q: <>Does the tool support WhatsApp Web?, 51 | a: <>Yes, WhatsApp Anyone also supports WhatsApp Web to send message or call unsaved number. Based on whether WhatsApp app is installed, you will either be redirected to WA app or WA web. 52 | }, 53 | { 54 | q: <>Do you have any how-to guides?, 55 | a: <>Read our how-to guides to increase WhatsApp productivity 56 | }, 57 | { 58 | q: <>Does WhatsApp Anyone have Android and iOS app?, 59 | a: <>WhatsApp Anyone is a Progressive Web App that can be installed on your home screen. Most browsers, and operating systems are supported - Android, iOS, Windows, MacOS, Linux. Add to Home Screen 60 | }, 61 | ] -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # WhatsApp Anyone 2 | 3 | WhatsApp Anyone is a tool to start WhatsApp chat with an unknown number, without need to save their contact. 4 | 5 | > Live @ https://whatsapp-anyone.pgxplorer.dev 6 | 7 | [](https://whatsapp-anyone.pgxplorer.dev) 8 | 9 | ### Top features 10 | - Add to Home Screen (for quick access) 11 | - Secure (your personal data is not saved) 12 | - Minimalist UI (to get things done) 13 | - Country drop down for fast interaction 14 | - Dark & light theme 15 | 16 | 17 | ### Tech 18 | * [next.js](nextjs.org) (a [react.js](reactjs.org) framework) - for server side rendering 19 | * [next-offline](https://github.com/hanford/next-offline) - for PWA 20 | * vanilla HTML & CSS 21 | * [React-Phone-Input-2](https://www.npmjs.com/package/react-phone-input-2) 22 | 23 | 24 | ### Installation 25 | This project requires [Node.js](https://nodejs.org/) to run. 26 | 27 | Install the dependencies and devDependencies and start the server. 28 | 29 | ```sh 30 | $ git clone https://github.com/cTxplorer/whatsapp-anyone.git 31 | $ cd whatsapp-anyone 32 | $ npm install 33 | $ npm run dev 34 | ``` 35 | 36 | ### Development 37 | 38 | Want to contribute? Great! 39 | 40 | NextJs provides hot reloading capablity - make a change in your file and instantaneously see your updates! 41 | 42 | Open your favorite Terminal and run this command - 43 | 44 | ```sh 45 | $ npm run dev 46 | ``` 47 | 48 | Open your favorite editor and start contributing! 49 | 50 | ### Todos 51 | 52 | - language localization 53 | - Improve styling on larger screens 54 | - add code comments 55 | - add contributing.md file 56 | 57 | 58 | ### License 59 | ---- 60 | MIT 61 | -------------------------------------------------------------------------------- /about.js: -------------------------------------------------------------------------------- 1 | import Head from 'next/head'; 2 | import Layout from '../components/Layout'; 3 | 4 | const About = () => ( 5 | <> 6 | 7 | About | Whatsapp unsaved contact 8 | 9 | 10 |

About us

11 |

Oh, hi. This is a side project built out of personal need

12 |
13 | 14 | ); 15 | 16 | export default About; -------------------------------------------------------------------------------- /components/DarkMode.js: -------------------------------------------------------------------------------- 1 | import { useEffect } from 'react'; 2 | import { posthog } from 'posthog-js' 3 | 4 | const setDarkMode = (active = false) => { 5 | const wrapper = document.querySelector(":root"); 6 | const modeName = active ? "dark" : "light"; 7 | wrapper.setAttribute("data-theme", modeName); 8 | localStorage.setItem("theme", modeName); 9 | }; 10 | 11 | const toggleDarkMode = () => { 12 | const theme = document.querySelector(":root").getAttribute("data-theme"); 13 | setDarkMode(theme === "light"); 14 | posthog.capture('WA - Toggled Dark Theme', { isDark: theme === "light"}); 15 | }; 16 | 17 | const toggleOnMatchMediaChange = e => { 18 | setDarkMode(e.matches); 19 | posthog.capture('WA - Toggled Dark Theme On System Change', { isDark: theme === "light"}); 20 | } 21 | 22 | const initDarkMode = () => { 23 | const themePreference = localStorage.getItem("theme"); 24 | const query = window.matchMedia("(prefers-color-scheme: dark)"); 25 | setDarkMode(themePreference ? themePreference === "dark" : query.matches); 26 | query.addEventListener("change", toggleOnMatchMediaChange); 27 | return query; 28 | }; 29 | 30 | 31 | const DarkMode = ({ children }) => { 32 | useEffect(() => { 33 | const query = initDarkMode(); 34 | return () => { 35 | query.removeEventListener("change", toggleOnMatchMediaChange); 36 | } 37 | }, []); 38 | return ( 39 | <> 40 | 41 | Turn on dark mode 42 | Turn off dark mode 43 | 44 | {children} 45 | 46 | ); 47 | } 48 | 49 | export default DarkMode; -------------------------------------------------------------------------------- /components/Form.js: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import PhoneInput from 'react-phone-input-2'; 3 | import { posthog } from 'posthog-js'; 4 | import { isPossibleNumber } from 'libphonenumber-js'; 5 | 6 | class Form extends React.Component { 7 | constructor(props) { 8 | super(props); 9 | this.state = { 10 | contactVal: '', 11 | contact: '', 12 | messageText: 'Hi!', 13 | showCCPrompt: false, 14 | } 15 | } 16 | 17 | onPhoneChange = (value, country) => { 18 | let isValid = false // Basic validation 19 | if (country.countryCode) { 20 | localStorage.setItem("lastSelectedCountryIso2", country.countryCode); 21 | isValid = isPossibleNumber(value, country.countryCode?.toUpperCase()); 22 | } 23 | this.setState({ 24 | contactVal: value, 25 | contact: value, 26 | isValid, 27 | showCCPrompt: false, 28 | }); 29 | this.forceUpdate(); 30 | } 31 | 32 | handleSubmit = (ev) => { 33 | ev.preventDefault(); 34 | 35 | if (this.state.isValid) { 36 | const fullContact = this.state.contact; 37 | const encodedMsg = encodeURIComponent(this.state.messageText); 38 | const waLink = `https://wa.me/${fullContact}?text=${encodedMsg}`; 39 | posthog.capture('WA - Opened WA chat'); 40 | window.open(waLink, "_blank"); 41 | } else { 42 | document 43 | .getElementsByClassName('wa-form')[0] 44 | .getElementsByTagName('input')[0] 45 | .focus(); 46 | posthog.capture('WA - Viewed Phone Input Error'); 47 | this.setState({ showCCPrompt: true }); 48 | } 49 | } 50 | 51 | render() { 52 | const { country } = this.props; 53 | return ( 54 |
55 |
56 |
57 |
the phone number seems correct!
58 |
59 |
60 |
61 | 76 |
77 | 80 |
81 |
82 | ) 83 | } 84 | } 85 | 86 | export default Form; -------------------------------------------------------------------------------- /components/HomePage.js: -------------------------------------------------------------------------------- 1 | import { useState, useEffect } from 'react'; 2 | import { useContext } from 'react'; 3 | import { CountryContext } from '../context/CountryContext'; 4 | import Layout from './Layout'; 5 | import Form from './Form'; 6 | import { faqs } from '../FAQs'; 7 | import MultiCards from './MultiCards'; 8 | 9 | // import styles from './HomePage.css'; 10 | 11 | const HomePage = () => { 12 | const [showA2HS, updateShowA2HS] = useState(false); 13 | const [deferredPrompt, updatedDeferredPrompt] = useState(null); 14 | const country = useContext(CountryContext); 15 | 16 | useEffect(() => { 17 | window.addEventListener('beforeinstallprompt', (e) => { 18 | e.preventDefault(); 19 | updateShowA2HS(true); 20 | updatedDeferredPrompt(e); 21 | }); 22 | }, []); 23 | 24 | const onA2hsClickHandler = () => { 25 | if (deferredPrompt) { 26 | deferredPrompt.prompt(); 27 | deferredPrompt.userChoice.then((choiceResult) => { 28 | if (choiceResult.outcome === 'accepted') { 29 | updateShowA2HS(false); 30 | } 31 | }); 32 | } 33 | } 34 | 35 | return ( 36 | <> 37 | 38 |
39 |
40 |
41 | 42 |

WhatsApp Anyone

43 |
44 |
45 |
46 |
47 |
48 |
    49 |
  • 50 |

    Open direct WhatsApp chat

    51 |
    without saving contact
    52 |
  • 53 |
  • 54 |

    Easy access from homescreen 

    55 |
    56 | light-weight · 57 | {showA2HS && " · "} 58 | 59 | {showA2HS ? "Add to Home Screen 📱" : ""} 60 | 61 |
    62 |
  • 63 |
  • 64 |

    It's very SIMPLE

    65 |
    no need to save number
    66 | {/*
    to message or call unsaved contact on WA
    */} 67 |
  • 68 |
69 |
70 |
71 |
72 | 73 |
74 |
75 |

Simple Tool, Many Use-cases

76 | How is this tool helping you? Please share your use-case, and we will feature it!! 92 | } 93 | ]} /> 94 |
95 |
96 | 97 |
98 |
99 |

Questions & Answers

100 |
101 | {faqs.map(faq => ( 102 |
103 | {faq.q} 104 | {faq.a} 105 |
106 | ))} 107 |
108 |
109 |
110 | 111 |
112 |
113 |
114 |

User Reviews

115 | “, 118 | content: <>Great work, thank you for sharing! I added the shortcut to my home screen so it is easy to use whenever. Thanks a lot!, 119 | }, 120 | { 121 | title: <>“, 122 | content: <>Fantastic project. Really hate to save someone’s number just to text them on WhatsApp. Love the source code too, very easy to read. 123 | } 124 | ]} /> 125 |
126 |
127 | 128 |
129 |
130 |
131 |

WARNING: WhatsApp Anyone is NOT for those..

132 | 150 |
151 |
152 | 153 |
154 | 162 |
163 | 164 | ); 165 | } 166 | 167 | export default HomePage; -------------------------------------------------------------------------------- /components/Layout.js: -------------------------------------------------------------------------------- 1 | import Head from 'next/head'; 2 | 3 | const Layout = (props) => ( 4 | <> 5 | 6 | WhatsApp without saving number - WhatsApp Anyone app 7 | 8 | 9 | 10 | {/* */} 11 | 12 | {/* Global site tag (gtag.js) - Google Analytics */} 13 | 14 |