Fuzzy String Match & Similarity Checker Online
Compare strings (Levenshtein, Jaro-Winkler, token set, trigram), find the best matches in a list and cluster duplicates, with Vietnamese accent folding.
Result
Press “Run” to see the result.
Three modes. compare (a, b) returns every score between 0 and 1: normalised Levenshtein, Jaro-Winkler, token sort and token set ratio (as rapidfuzz), trigram similarity (as PostgreSQL pg_trgm) and combined, their mean, plus the edit distance. search (query, choices up to 10,000) returns the best matches above threshold with their index. dedupe (items up to 5,000) groups near-duplicates into clusters with a representative and returns the deduplicated list; pairs are blocked by shared trigrams, so large lists stay fast.
Before comparing, strings are normalised: case and Vietnamese accents are folded (Nguyễn = nguyen, đ = d), punctuation becomes spaces and common Vietnamese abbreviations are expanded (TP. = thành phố, Q. = quận, P. = phường, Cty = công ty, CP = cổ phần, TM = thương mại, HCM = Hồ Chí Minh…). Turn these off with keep_accents, case_sensitive and abbreviations=false, and drop noise words with ignore (for example "tnhh, cong ty").
Choose the score with algorithm: token_set for names whose word order or extra words vary (company names, product titles), jaro_winkler for short strings and typos at the end, levenshtein for codes, trigram for long texts. Nothing is stored.
Use this in your code
curl -X POST "https://apibox.io.vn/v1/fuzzy-match" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"a":"Cty TNHH Thương mại ABC, Q.1, TP.HCM","b":"Công ty TNHH TM ABC Quận 1 Hồ Chí Minh"}'const res = await fetch('https://apibox.io.vn/v1/fuzzy-match', {
method: 'POST',
headers: {
Authorization: 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json',
},
body: JSON.stringify({
"a": "Cty TNHH Thương mại ABC, Q.1, TP.HCM",
"b": "Công ty TNHH TM ABC Quận 1 Hồ Chí Minh"
}),
});
const data = await res.json();
console.log(data);import requests
res = requests.post(
"https://apibox.io.vn/v1/fuzzy-match",
headers={"Authorization": "Bearer YOUR_API_KEY"},
json={"a": "Cty TNHH Thương mại ABC, Q.1, TP.HCM", "b": "Công ty TNHH TM ABC Quận 1 Hồ Chí Minh"},
timeout=30,
)
print(res.json())<?php
$ch = curl_init('https://apibox.io.vn/v1/fuzzy-match');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_HTTPHEADER => ['Authorization: Bearer YOUR_API_KEY', 'Content-Type: application/json'],
CURLOPT_POSTFIELDS => '{"a":"Cty TNHH Thương mại ABC, Q.1, TP.HCM","b":"Công ty TNHH TM ABC Quận 1 Hồ Chí Minh"}',
]);
$response = curl_exec($ch);
print_r(json_decode($response, true));API documentation → Get a free API key
FAQ
Which score should I use?
combined is a good default. token_set ignores word order and extra words, jaro_winkler favours common prefixes, levenshtein counts edits, trigram suits longer texts.
Are Vietnamese accents ignored?
Yes by default, together with case and punctuation; set keep_accents=true when "Hà" and "Ha" must differ.
How large can the lists be?
search accepts 10,000 choices, dedupe 5,000 items of up to 1,000 characters each.