Namsor

Gender API – Predict gender from first or full names

Namsor's Gender API accurately predicts whether a person is likely male or female based on their name.
It supports multiple input formats: full name, first name only, or a combination of first and last names. To further boost accuracy, you can specify the country of origin. Our API is optimized for global usage and includes advanced support for Chinese, Japanese, and many non-Latin alphabets.


Namsor's AI is built on advanced morphological analysis, making it one of the most accurate gender checker APIs available. Trained on billions of names, our specialized algorithms lead the field in identifying whether a name is male or female.

600+Research contributions

99.99%Names availability

11B billionsNames processed

Genderize Name

Gender from first name , last name (optional).

{
    "script": "LATIN",
    "id": "b590b04c-da23-4f2f-a334-aee384ee420a",
    "firstName": "Keith",
    "lastName": "Haring",
    "likelyGender": "male",
    "genderScale": -0.8126510374561324,
    "score": 12.516892456249645,
    "probabilityCalibrated": 0.9063255187280662
}

Genderize Name API analyzes a first name and optionally a last name to determine the most likely gender. This API feature offers slightly higher accuracy than Genderize Full Name, especially when both first and last names are provided. The response includes the predicted gender along with a calibrated probability. If the probability falls between 45% and 55%, the name is likely unisex.

information

If the country of residence or origin is known, the Genderize Name Geo feature will be more precise, taking better account of the local context.

  • Precision:Precision gauge
  • Cost: 1 credit per name.
  • Description: Returns the most likely gender of up to 100 first names and last names (optional).
  • More about: Genderize Name

HTTP request

http request
POST
https://v2.namsor.com/NamSorAPIv2/api2/json/genderBatch
Request header
PropertyRequiredDescription
X-API-KEYRequiredYour Namsor's services API key
information

To get an API key for free, please create an account.

Request body
NameTypeRequiredDescription
personalNamesArray of objectsRequiredA list of personal names.
[{...}].idStringOptionalUnique identifier.
[{...}].firstNameStringRequiredFirst name, given name, nickname.
[{...}].lastNameStringOptionalLast name, family name, surname.
Response
NameTypeDescriptionEnumerators
personalNamesArray of objectsList of submitted names genderized.
[{...}].scriptStringName of the script used for the name, in ISO 15924 format.Script
[{...}].idStringProvided unique identifier.
[{...}].firstNameStringSubmitted first name.
[{...}].lastNameStringSubmitted last name.
[{...}].likelyGenderStringMost likely gender.Genders
[{...}].genderScaleNumberGender scale ranging from -1 (male) to +1 (female).
[{...}].scoreNumberHigher implies a more reliable result, score is not normalized.
[{...}].probabilityCalibratedNumberHigher implies a more reliable result, ranges from 0 to 1.

Code sample:

Genderize Name code sample for shell:

curl --request POST \ 
--url https://v2.namsor.com/NamSorAPIv2/api2/json/genderBatch \
--header 'X-API-KEY: your-api-key' \
--header 'Accept: application/json'
--header 'Content-Type: application/json' \
--data '{"personalNames":[{"id":"b590b04c-da23-4f2f-a334-aee384ee420a","firstName":"Keith","lastName":"Haring"}]}'

Body parameter:

{
  "personalNames": [
    {
      "id": "b590b04c-da23-4f2f-a334-aee384ee420a",
      "firstName": "Keith",
      "lastName": "Haring"
    }
  ]
}

The above command returns JSON structured like this:

{
    "personalNames": [
        {
            "script": "LATIN",
            "id": "b590b04c-da23-4f2f-a334-aee384ee420a",
            "firstName": "Keith",
            "lastName": "Haring",
            "likelyGender": "male",
            "genderScale": -0.8126510374561324,
            "score": 12.516892456249645,
            "probabilityCalibrated": 0.9063255187280662
        }
    ]
}

Genderize Name code sample for java:

HttpResponse<String> response = Unirest.post("https://v2.namsor.com/NamSorAPIv2/api2/json/genderBatch")
.header("X-API-KEY", "your-api-key")
.header("Accept", "application/json")
.header("Content-Type", "application/json")
.body("{\"personalNames\":[{\"id\":\"b590b04c-da23-4f2f-a334-aee384ee420a\",\"firstName\":\"Keith\",\"lastName\":\"Haring\"}]}")
.asString();

Body parameter:

{
  "personalNames": [
    {
      "id": "b590b04c-da23-4f2f-a334-aee384ee420a",
      "firstName": "Keith",
      "lastName": "Haring"
    }
  ]
}

The above command returns JSON structured like this:

{
    "personalNames": [
        {
            "script": "LATIN",
            "id": "b590b04c-da23-4f2f-a334-aee384ee420a",
            "firstName": "Keith",
            "lastName": "Haring",
            "likelyGender": "male",
            "genderScale": -0.8126510374561324,
            "score": 12.516892456249645,
            "probabilityCalibrated": 0.9063255187280662
        }
    ]
}

Genderize Name code sample for python:

import requests

url = "https://v2.namsor.com/NamSorAPIv2/api2/json/genderBatch"

payload = {
  "personalNames": [
    {
      "id": "b590b04c-da23-4f2f-a334-aee384ee420a",
      "firstName": "Keith",
      "lastName": "Haring"
    }
  ]
}
headers = {
    "X-API-KEY": "your-api-key",
    "Accept": "application/json",
    "Content-Type": "application/json"
}

response = requests.request("POST", url, json=payload, headers=headers)

print(response.text)

Body parameter:

{
  "personalNames": [
    {
      "id": "b590b04c-da23-4f2f-a334-aee384ee420a",
      "firstName": "Keith",
      "lastName": "Haring"
    }
  ]
}

The above command returns JSON structured like this:

{
    "personalNames": [
        {
            "script": "LATIN",
            "id": "b590b04c-da23-4f2f-a334-aee384ee420a",
            "firstName": "Keith",
            "lastName": "Haring",
            "likelyGender": "male",
            "genderScale": -0.8126510374561324,
            "score": 12.516892456249645,
            "probabilityCalibrated": 0.9063255187280662
        }
    ]
}

Genderize Name code sample for javascript:

const response = await fetch("https://v2.namsor.com/NamSorAPIv2/api2/json/genderBatch", {
  "method": "POST",
  "headers": {
    "X-API-KEY": "your-api-key",
    "Accept": "application/json",
    "Content-Type": "application/json"
  },
  "body": JSON.stringify({
  "personalNames": [
    {
      "id": "b590b04c-da23-4f2f-a334-aee384ee420a",
      "firstName": "Keith",
      "lastName": "Haring"
    }
  ]
})
});

if (response.ok) {
  const data = await response.json(); // Extract JSON data from response
  console.log(data); // View data in the console
} else {
  console.error("The request failed with status:", response.status, response);
}

Body parameter:

{
  "personalNames": [
    {
      "id": "b590b04c-da23-4f2f-a334-aee384ee420a",
      "firstName": "Keith",
      "lastName": "Haring"
    }
  ]
}

The above command returns JSON structured like this:

{
    "personalNames": [
        {
            "script": "LATIN",
            "id": "b590b04c-da23-4f2f-a334-aee384ee420a",
            "firstName": "Keith",
            "lastName": "Haring",
            "likelyGender": "male",
            "genderScale": -0.8126510374561324,
            "score": 12.516892456249645,
            "probabilityCalibrated": 0.9063255187280662
        }
    ]
}
  • Precision:Precision gauge
  • Cost: 1 credit per name.
  • Description: Returns the most likely gender of a first name and a last name.
information

For requests with a GET method all parameters are required. For more ease in the use of our requests we recommend that you use the POST method.

HTTP request

http request
GET
https://v2.namsor.com/NamSorAPIv2/api2/json/gender/{firstName}/{lastName}
Request header
PropertyRequiredDescription
X-API-KEYRequiredYour Namsor's services API key
information

To get an API key for free, please create an account.

Request parameters
NameTypeRequiredDescription
firstNameStringRequiredFirst name, given name, nickname.
lastNameStringRequiredLast name, family name, surname.
Response
NameTypeDescriptionEnumerators
scriptStringName of the script used for the name, in ISO 15924 format.Script
idStringProvided unique identifier.
firstNameStringSubmitted first name.
lastNameStringSubmitted last name.
likelyGenderStringMost likely gender.Genders
genderScaleNumberGender scale ranging from -1 (male) to +1 (female).
scoreNumberHigher implies a more reliable result, score is not normalized.
probabilityCalibratedNumberHigher implies a more reliable result, ranges from 0 to 1.

Code sample:

Genderize Name code sample for shell:

curl --request GET \ 
--url https://v2.namsor.com/NamSorAPIv2/api2/json/gender/Keith/Haring \
--header 'X-API-KEY: your-api-key' \
--header 'Accept: application/json'

The above command returns JSON structured like this:

{
    "script": "LATIN",
    "id": "b590b04c-da23-4f2f-a334-aee384ee420a",
    "firstName": "Keith",
    "lastName": "Haring",
    "likelyGender": "male",
    "genderScale": -0.8126510374561324,
    "score": 12.516892456249645,
    "probabilityCalibrated": 0.9063255187280662
}

Genderize Name code sample for java:

HttpResponse<String> response = Unirest.get("https://v2.namsor.com/NamSorAPIv2/api2/json/gender/Keith/Haring")
.header("X-API-KEY", "your-api-key")
.header("Accept", "application/json")
.asString();

The above command returns JSON structured like this:

{
    "script": "LATIN",
    "id": "b590b04c-da23-4f2f-a334-aee384ee420a",
    "firstName": "Keith",
    "lastName": "Haring",
    "likelyGender": "male",
    "genderScale": -0.8126510374561324,
    "score": 12.516892456249645,
    "probabilityCalibrated": 0.9063255187280662
}

Genderize Name code sample for python:

import requests

url = "https://v2.namsor.com/NamSorAPIv2/api2/json/gender/Keith/Haring"

headers = {
  "X-API-KEY": "your-api-key",
 "Accept": "application/json"
}

response = requests.request("GET", url, headers=headers)

print(response.text)

The above command returns JSON structured like this:

{
    "script": "LATIN",
    "id": "b590b04c-da23-4f2f-a334-aee384ee420a",
    "firstName": "Keith",
    "lastName": "Haring",
    "likelyGender": "male",
    "genderScale": -0.8126510374561324,
    "score": 12.516892456249645,
    "probabilityCalibrated": 0.9063255187280662
}

Genderize Name code sample for javascript:

const response = await fetch("https://v2.namsor.com/NamSorAPIv2/api2/json/gender/Keith/Haring", {
  "method": "GET",
  "headers": {
    "X-API-KEY": "your-api-key",
    "Accept": "application/json"
  }
});

if (response.ok) {
  const data = await response.json(); // Extract JSON data from response
  console.log(data); // View data in the console
} else {
  console.error("The request failed with status:", response.status, response);
}

The above command returns JSON structured like this:

{
    "script": "LATIN",
    "id": "b590b04c-da23-4f2f-a334-aee384ee420a",
    "firstName": "Keith",
    "lastName": "Haring",
    "likelyGender": "male",
    "genderScale": -0.8126510374561324,
    "score": 12.516892456249645,
    "probabilityCalibrated": 0.9063255187280662
}

Genderize Name Geo

Gender from first name , last name (optional), country code .

{
    "script": "LATIN",
    "id": "27fb45db-eddf-40d0-95c1-de9978a166b0",
    "firstName": "Keith",
    "lastName": "Haring",
    "likelyGender": "male",
    "genderScale": -0.8889514731555574,
    "score": 16.03594419932244,
    "probabilityCalibrated": 0.9444757365777787
}

Genderize Name Geo enhances the basic Genderize Name feature by taking into account a country of residence. This API analyzes a first name and optionally a last name to determine the most likely gender with improved accuracy. The response includes the predicted gender along with a calibrated probability. If the probability falls between 45% and 55%, the name is likely unisex.

  • Precision:Precision gauge
  • Cost: 1 credit per name.
  • Description: Returns the most likely gender of up to 100 first names and last names (optional) using their geographic context.
  • More about: Genderize Name Geo

HTTP request

http request
POST
https://v2.namsor.com/NamSorAPIv2/api2/json/genderGeoBatch
Request header
PropertyRequiredDescription
X-API-KEYRequiredYour Namsor's services API key
information

To get an API key for free, please create an account.

Request body
NameTypeRequiredDescription
personalNamesArray of objectsRequiredA list of personal names with their country of residence.
[{...}].idStringOptionalUnique identifier.
[{...}].firstNameStringRequiredFirst name, given name, nickname.
[{...}].lastNameStringOptionalLast name, family name, surname.
[{...}].countryIso2StringRequiredMost likely country of residence, in ISO 3166-1 alpha-2 format.
Response
NameTypeDescriptionEnumerators
personalNamesArray of objectsList of submitted names genderized.
[{...}].scriptStringName of the script used for the name, in ISO 15924 format.Script
[{...}].idStringProvided unique identifier.
[{...}].firstNameStringSubmitted first name.
[{...}].lastNameStringSubmitted last name.
[{...}].likelyGenderStringMost likely gender.Genders
[{...}].genderScaleNumberGender scale ranging from -1 (male) to +1 (female).
[{...}].scoreNumberHigher implies a more reliable result, score is not normalized.
[{...}].probabilityCalibratedNumberHigher implies a more reliable result, ranges from 0 to 1.

Code sample:

Genderize Name Geo code sample for shell:

curl --request POST \ 
--url https://v2.namsor.com/NamSorAPIv2/api2/json/genderGeoBatch \
--header 'X-API-KEY: your-api-key' \
--header 'Accept: application/json'
--header 'Content-Type: application/json' \
--data '{"personalNames":[{"id":"27fb45db-eddf-40d0-95c1-de9978a166b0","firstName":"Keith","lastName":"Haring","countryIso2":"US"}]}'

Body parameter:

{
  "personalNames": [
    {
      "id": "27fb45db-eddf-40d0-95c1-de9978a166b0",
      "firstName": "Keith",
      "lastName": "Haring",
      "countryIso2": "US"
    }
  ]
}

The above command returns JSON structured like this:

{
    "personalNames": [
        {
            "script": "LATIN",
            "id": "27fb45db-eddf-40d0-95c1-de9978a166b0",
            "firstName": "Keith",
            "lastName": "Haring",
            "likelyGender": "male",
            "genderScale": -0.8889514731555574,
            "score": 16.03594419932244,
            "probabilityCalibrated": 0.9444757365777787
        }
    ]
}

Genderize Name Geo code sample for java:

HttpResponse<String> response = Unirest.post("https://v2.namsor.com/NamSorAPIv2/api2/json/genderGeoBatch")
.header("X-API-KEY", "your-api-key")
.header("Accept", "application/json")
.header("Content-Type", "application/json")
.body("{\"personalNames\":[{\"id\":\"27fb45db-eddf-40d0-95c1-de9978a166b0\",\"firstName\":\"Keith\",\"lastName\":\"Haring\",\"countryIso2\":\"US\"}]}")
.asString();

Body parameter:

{
  "personalNames": [
    {
      "id": "27fb45db-eddf-40d0-95c1-de9978a166b0",
      "firstName": "Keith",
      "lastName": "Haring",
      "countryIso2": "US"
    }
  ]
}

The above command returns JSON structured like this:

{
    "personalNames": [
        {
            "script": "LATIN",
            "id": "27fb45db-eddf-40d0-95c1-de9978a166b0",
            "firstName": "Keith",
            "lastName": "Haring",
            "likelyGender": "male",
            "genderScale": -0.8889514731555574,
            "score": 16.03594419932244,
            "probabilityCalibrated": 0.9444757365777787
        }
    ]
}

Genderize Name Geo code sample for python:

import requests

url = "https://v2.namsor.com/NamSorAPIv2/api2/json/genderGeoBatch"

payload = {
  "personalNames": [
    {
      "id": "27fb45db-eddf-40d0-95c1-de9978a166b0",
      "firstName": "Keith",
      "lastName": "Haring",
      "countryIso2": "US"
    }
  ]
}
headers = {
    "X-API-KEY": "your-api-key",
    "Accept": "application/json",
    "Content-Type": "application/json"
}

response = requests.request("POST", url, json=payload, headers=headers)

print(response.text)

Body parameter:

{
  "personalNames": [
    {
      "id": "27fb45db-eddf-40d0-95c1-de9978a166b0",
      "firstName": "Keith",
      "lastName": "Haring",
      "countryIso2": "US"
    }
  ]
}

The above command returns JSON structured like this:

{
    "personalNames": [
        {
            "script": "LATIN",
            "id": "27fb45db-eddf-40d0-95c1-de9978a166b0",
            "firstName": "Keith",
            "lastName": "Haring",
            "likelyGender": "male",
            "genderScale": -0.8889514731555574,
            "score": 16.03594419932244,
            "probabilityCalibrated": 0.9444757365777787
        }
    ]
}

Genderize Name Geo code sample for javascript:

const response = await fetch("https://v2.namsor.com/NamSorAPIv2/api2/json/genderGeoBatch", {
  "method": "POST",
  "headers": {
    "X-API-KEY": "your-api-key",
    "Accept": "application/json",
    "Content-Type": "application/json"
  },
  "body": JSON.stringify({
  "personalNames": [
    {
      "id": "27fb45db-eddf-40d0-95c1-de9978a166b0",
      "firstName": "Keith",
      "lastName": "Haring",
      "countryIso2": "US"
    }
  ]
})
});

if (response.ok) {
  const data = await response.json(); // Extract JSON data from response
  console.log(data); // View data in the console
} else {
  console.error("The request failed with status:", response.status, response);
}

Body parameter:

{
  "personalNames": [
    {
      "id": "27fb45db-eddf-40d0-95c1-de9978a166b0",
      "firstName": "Keith",
      "lastName": "Haring",
      "countryIso2": "US"
    }
  ]
}

The above command returns JSON structured like this:

{
    "personalNames": [
        {
            "script": "LATIN",
            "id": "27fb45db-eddf-40d0-95c1-de9978a166b0",
            "firstName": "Keith",
            "lastName": "Haring",
            "likelyGender": "male",
            "genderScale": -0.8889514731555574,
            "score": 16.03594419932244,
            "probabilityCalibrated": 0.9444757365777787
        }
    ]
}
  • Precision:Precision gauge
  • Cost: 1 credit per name.
  • Description: Returns the most likely gender of a first name and a last name using its geographic context.
information

For requests with a GET method all parameters are required. For more ease in the use of our requests we recommend that you use the POST method.

HTTP request

http request
GET
https://v2.namsor.com/NamSorAPIv2/api2/json/genderGeo/{firstName}/{lastName}/{countryIso2}
Request header
PropertyRequiredDescription
X-API-KEYRequiredYour Namsor's services API key
information

To get an API key for free, please create an account.

Request parameters
NameTypeRequiredDescription
firstNameStringRequiredFirst name, given name, nickname.
lastNameStringRequiredLast name, family name, surname.
countryIso2StringRequiredMost likely country of residence, in ISO 3166-1 alpha-2 format.
Response
NameTypeDescriptionEnumerators
scriptStringName of the script used for the name, in ISO 15924 format.Script
idStringProvided unique identifier.
firstNameStringSubmitted first name.
lastNameStringSubmitted last name.
likelyGenderStringMost likely gender.Genders
genderScaleNumberGender scale ranging from -1 (male) to +1 (female).
scoreNumberHigher implies a more reliable result, score is not normalized.
probabilityCalibratedNumberHigher implies a more reliable result, ranges from 0 to 1.

Code sample:

Genderize Name Geo code sample for shell:

curl --request GET \ 
--url https://v2.namsor.com/NamSorAPIv2/api2/json/genderGeo/Keith/Haring/US \
--header 'X-API-KEY: your-api-key' \
--header 'Accept: application/json'

The above command returns JSON structured like this:

{
    "script": "LATIN",
    "id": "27fb45db-eddf-40d0-95c1-de9978a166b0",
    "firstName": "Keith",
    "lastName": "Haring",
    "likelyGender": "male",
    "genderScale": -0.8889514731555574,
    "score": 16.03594419932244,
    "probabilityCalibrated": 0.9444757365777787
}

Genderize Name Geo code sample for java:

HttpResponse<String> response = Unirest.get("https://v2.namsor.com/NamSorAPIv2/api2/json/genderGeo/Keith/Haring/US")
.header("X-API-KEY", "your-api-key")
.header("Accept", "application/json")
.asString();

The above command returns JSON structured like this:

{
    "script": "LATIN",
    "id": "27fb45db-eddf-40d0-95c1-de9978a166b0",
    "firstName": "Keith",
    "lastName": "Haring",
    "likelyGender": "male",
    "genderScale": -0.8889514731555574,
    "score": 16.03594419932244,
    "probabilityCalibrated": 0.9444757365777787
}

Genderize Name Geo code sample for python:

import requests

url = "https://v2.namsor.com/NamSorAPIv2/api2/json/genderGeo/Keith/Haring/US"

headers = {
  "X-API-KEY": "your-api-key",
 "Accept": "application/json"
}

response = requests.request("GET", url, headers=headers)

print(response.text)

The above command returns JSON structured like this:

{
    "script": "LATIN",
    "id": "27fb45db-eddf-40d0-95c1-de9978a166b0",
    "firstName": "Keith",
    "lastName": "Haring",
    "likelyGender": "male",
    "genderScale": -0.8889514731555574,
    "score": 16.03594419932244,
    "probabilityCalibrated": 0.9444757365777787
}

Genderize Name Geo code sample for javascript:

const response = await fetch("https://v2.namsor.com/NamSorAPIv2/api2/json/genderGeo/Keith/Haring/US", {
  "method": "GET",
  "headers": {
    "X-API-KEY": "your-api-key",
    "Accept": "application/json"
  }
});

if (response.ok) {
  const data = await response.json(); // Extract JSON data from response
  console.log(data); // View data in the console
} else {
  console.error("The request failed with status:", response.status, response);
}

The above command returns JSON structured like this:

{
    "script": "LATIN",
    "id": "27fb45db-eddf-40d0-95c1-de9978a166b0",
    "firstName": "Keith",
    "lastName": "Haring",
    "likelyGender": "male",
    "genderScale": -0.8889514731555574,
    "score": 16.03594419932244,
    "probabilityCalibrated": 0.9444757365777787
}

Genderize Full Name

Gender from full name .

{
    "script": "LATIN",
    "id": "0f472330-11a9-49ad-a0f5-bcac90a3f6bf",
    "name": "Keith Haring",
    "likelyGender": "male",
    "genderScale": -0.8744219712791637,
    "score": 11.2727995452283,
    "probabilityCalibrated": 0.9372109856395818
}

Genderize Full Name API analyzes a full name (first and last name combined) without requiring them to be split, to identify the most likely gender. The API response includes the predicted gender along with a calibrated probability. If the probability falls between 45% and 55%, the name is likely unisex.

information

If the first and last name are clearly identifiable, the Genderize Name feature will be slightly more accurate.

  • Precision:Precision gauge
  • Cost: 1 credit per name.
  • Description: Returns the most likely gender of up to 100 unsplit full names.
  • More about: Genderize Full Name

HTTP request

http request
POST
https://v2.namsor.com/NamSorAPIv2/api2/json/genderFullBatch
Request header
PropertyRequiredDescription
X-API-KEYRequiredYour Namsor's services API key
information

To get an API key for free, please create an account.

Request body
NameTypeRequiredDescription
personalNamesArray of objectsRequiredA list of personal full names.
[{...}].idStringOptionalUnique identifier.
[{...}].nameStringRequiredUnsplit full name (first name and last name).
Response
NameTypeDescriptionEnumerators
personalNamesArray of objectsList of submitted full names genderized.
[{...}].scriptStringName of the script used for the name, in ISO 15924 format.Script
[{...}].idStringProvided unique identifier.
[{...}].nameStringSubmitted full name.
[{...}].likelyGenderStringMost likely gender.Genders
[{...}].genderScaleNumberGender scale ranging from -1 (male) to +1 (female).
[{...}].scoreNumberHigher implies a more reliable result, score is not normalized.
[{...}].probabilityCalibratedNumberHigher implies a more reliable result, ranges from 0 to 1.

Code sample:

Genderize Full Name code sample for shell:

curl --request POST \ 
--url https://v2.namsor.com/NamSorAPIv2/api2/json/genderFullBatch \
--header 'X-API-KEY: your-api-key' \
--header 'Accept: application/json'
--header 'Content-Type: application/json' \
--data '{"personalNames":[{"id":"0f472330-11a9-49ad-a0f5-bcac90a3f6bf","name":"Keith Haring"}]}'

Body parameter:

{
  "personalNames": [
    {
      "id": "0f472330-11a9-49ad-a0f5-bcac90a3f6bf",
      "name": "Keith Haring"
    }
  ]
}

The above command returns JSON structured like this:

{
    "personalNames": [
        {
            "script": "LATIN",
            "id": "0f472330-11a9-49ad-a0f5-bcac90a3f6bf",
            "name": "Keith Haring",
            "likelyGender": "male",
            "genderScale": -0.8744219712791637,
            "score": 11.2727995452283,
            "probabilityCalibrated": 0.9372109856395818
        }
    ]
}

Genderize Full Name code sample for java:

HttpResponse<String> response = Unirest.post("https://v2.namsor.com/NamSorAPIv2/api2/json/genderFullBatch")
.header("X-API-KEY", "your-api-key")
.header("Accept", "application/json")
.header("Content-Type", "application/json")
.body("{\"personalNames\":[{\"id\":\"0f472330-11a9-49ad-a0f5-bcac90a3f6bf\",\"name\":\"Keith Haring\"}]}")
.asString();

Body parameter:

{
  "personalNames": [
    {
      "id": "0f472330-11a9-49ad-a0f5-bcac90a3f6bf",
      "name": "Keith Haring"
    }
  ]
}

The above command returns JSON structured like this:

{
    "personalNames": [
        {
            "script": "LATIN",
            "id": "0f472330-11a9-49ad-a0f5-bcac90a3f6bf",
            "name": "Keith Haring",
            "likelyGender": "male",
            "genderScale": -0.8744219712791637,
            "score": 11.2727995452283,
            "probabilityCalibrated": 0.9372109856395818
        }
    ]
}

Genderize Full Name code sample for python:

import requests

url = "https://v2.namsor.com/NamSorAPIv2/api2/json/genderFullBatch"

payload = {
  "personalNames": [
    {
      "id": "0f472330-11a9-49ad-a0f5-bcac90a3f6bf",
      "name": "Keith Haring"
    }
  ]
}
headers = {
    "X-API-KEY": "your-api-key",
    "Accept": "application/json",
    "Content-Type": "application/json"
}

response = requests.request("POST", url, json=payload, headers=headers)

print(response.text)

Body parameter:

{
  "personalNames": [
    {
      "id": "0f472330-11a9-49ad-a0f5-bcac90a3f6bf",
      "name": "Keith Haring"
    }
  ]
}

The above command returns JSON structured like this:

{
    "personalNames": [
        {
            "script": "LATIN",
            "id": "0f472330-11a9-49ad-a0f5-bcac90a3f6bf",
            "name": "Keith Haring",
            "likelyGender": "male",
            "genderScale": -0.8744219712791637,
            "score": 11.2727995452283,
            "probabilityCalibrated": 0.9372109856395818
        }
    ]
}

Genderize Full Name code sample for javascript:

const response = await fetch("https://v2.namsor.com/NamSorAPIv2/api2/json/genderFullBatch", {
  "method": "POST",
  "headers": {
    "X-API-KEY": "your-api-key",
    "Accept": "application/json",
    "Content-Type": "application/json"
  },
  "body": JSON.stringify({
  "personalNames": [
    {
      "id": "0f472330-11a9-49ad-a0f5-bcac90a3f6bf",
      "name": "Keith Haring"
    }
  ]
})
});

if (response.ok) {
  const data = await response.json(); // Extract JSON data from response
  console.log(data); // View data in the console
} else {
  console.error("The request failed with status:", response.status, response);
}

Body parameter:

{
  "personalNames": [
    {
      "id": "0f472330-11a9-49ad-a0f5-bcac90a3f6bf",
      "name": "Keith Haring"
    }
  ]
}

The above command returns JSON structured like this:

{
    "personalNames": [
        {
            "script": "LATIN",
            "id": "0f472330-11a9-49ad-a0f5-bcac90a3f6bf",
            "name": "Keith Haring",
            "likelyGender": "male",
            "genderScale": -0.8744219712791637,
            "score": 11.2727995452283,
            "probabilityCalibrated": 0.9372109856395818
        }
    ]
}
  • Precision:Precision gauge
  • Cost: 1 credit per name.
  • Description: Returns the most likely gender of an unsplit full name.
information

For requests with a GET method all parameters are required. For more ease in the use of our requests we recommend that you use the POST method.

HTTP request

http request
GET
https://v2.namsor.com/NamSorAPIv2/api2/json/genderFull/{name}
Request header
PropertyRequiredDescription
X-API-KEYRequiredYour Namsor's services API key
information

To get an API key for free, please create an account.

Request parameters
NameTypeRequiredDescription
nameStringRequiredUnsplit full name (first name and last name).
Response
NameTypeDescriptionEnumerators
scriptStringName of the script used for the name, in ISO 15924 format.Script
idStringProvided unique identifier.
nameStringSubmitted full name.
likelyGenderStringMost likely gender.Genders
genderScaleNumberGender scale ranging from -1 (male) to +1 (female).
scoreNumberHigher implies a more reliable result, score is not normalized.
probabilityCalibratedNumberHigher implies a more reliable result, ranges from 0 to 1.

Code sample:

Genderize Full Name code sample for shell:

curl --request GET \ 
--url https://v2.namsor.com/NamSorAPIv2/api2/json/genderFull/Keith%20Haring \
--header 'X-API-KEY: your-api-key' \
--header 'Accept: application/json'

The above command returns JSON structured like this:

{
    "script": "LATIN",
    "id": "0f472330-11a9-49ad-a0f5-bcac90a3f6bf",
    "name": "Keith Haring",
    "likelyGender": "male",
    "genderScale": -0.8744219712791637,
    "score": 11.2727995452283,
    "probabilityCalibrated": 0.9372109856395818
}

Genderize Full Name code sample for java:

HttpResponse<String> response = Unirest.get("https://v2.namsor.com/NamSorAPIv2/api2/json/genderFull/Keith%20Haring")
.header("X-API-KEY", "your-api-key")
.header("Accept", "application/json")
.asString();

The above command returns JSON structured like this:

{
    "script": "LATIN",
    "id": "0f472330-11a9-49ad-a0f5-bcac90a3f6bf",
    "name": "Keith Haring",
    "likelyGender": "male",
    "genderScale": -0.8744219712791637,
    "score": 11.2727995452283,
    "probabilityCalibrated": 0.9372109856395818
}

Genderize Full Name code sample for python:

import requests

url = "https://v2.namsor.com/NamSorAPIv2/api2/json/genderFull/Keith%20Haring"

headers = {
  "X-API-KEY": "your-api-key",
 "Accept": "application/json"
}

response = requests.request("GET", url, headers=headers)

print(response.text)

The above command returns JSON structured like this:

{
    "script": "LATIN",
    "id": "0f472330-11a9-49ad-a0f5-bcac90a3f6bf",
    "name": "Keith Haring",
    "likelyGender": "male",
    "genderScale": -0.8744219712791637,
    "score": 11.2727995452283,
    "probabilityCalibrated": 0.9372109856395818
}

Genderize Full Name code sample for javascript:

const response = await fetch("https://v2.namsor.com/NamSorAPIv2/api2/json/genderFull/Keith%20Haring", {
  "method": "GET",
  "headers": {
    "X-API-KEY": "your-api-key",
    "Accept": "application/json"
  }
});

if (response.ok) {
  const data = await response.json(); // Extract JSON data from response
  console.log(data); // View data in the console
} else {
  console.error("The request failed with status:", response.status, response);
}

The above command returns JSON structured like this:

{
    "script": "LATIN",
    "id": "0f472330-11a9-49ad-a0f5-bcac90a3f6bf",
    "name": "Keith Haring",
    "likelyGender": "male",
    "genderScale": -0.8744219712791637,
    "score": 11.2727995452283,
    "probabilityCalibrated": 0.9372109856395818
}

Genderize Full Name Geo

Gender from full name , country code .

{
    "script": "LATIN",
    "id": "3a2d203a-a6a4-42f9-acd1-1b5c56c7d39f",
    "name": "Keith Haring",
    "likelyGender": "male",
    "genderScale": -0.8716298606148474,
    "score": 11.225679376737641,
    "probabilityCalibrated": 0.9358149303074237
}

Genderize Full Name Geo improves upon Genderize Full Name by incorporating a country of residence into the analysis. This API evaluates the full name to determine the most likely gender with enhanced accuracy. The response includes the predicted gender along with a calibrated probability. If the probability falls between 45% and 55%, the name is likely unisex.

information

If the first and last name are clearly identifiable, the Genderize Name Geo feature will be slightly more accurate.

  • Precision:Precision gauge
  • Cost: 1 credit per name.
  • Description: Returns the most likely gender of up to 100 unsplit full names, according to their geographic context.
  • More about: Genderize Full Name Geo

HTTP request

http request
POST
https://v2.namsor.com/NamSorAPIv2/api2/json/genderFullGeoBatch
Request header
PropertyRequiredDescription
X-API-KEYRequiredYour Namsor's services API key
information

To get an API key for free, please create an account.

Request body
NameTypeRequiredDescription
personalNamesArray of objectsRequiredA list of personal full names with their country of residence.
[{...}].idStringOptionalUnique identifier.
[{...}].nameStringRequiredUnsplit full name (first name and last name).
[{...}].countryIso2StringRequiredCountry of residence, in ISO 3166-1 alpha-2 format.
Response
NameTypeDescriptionEnumerators
personalNamesArray of objectsList of submitted full names genderized.
[{...}].scriptStringName of the script used for the name, in ISO 15924 format.Script
[{...}].idStringProvided unique identifier.
[{...}].nameStringSubmitted full name.
[{...}].likelyGenderStringMost likely gender.Genders
[{...}].genderScaleNumberGender scale ranging from -1 (male) to +1 (female).
[{...}].scoreNumberHigher implies a more reliable result, score is not normalized.
[{...}].probabilityCalibratedNumberHigher implies a more reliable result, ranges from 0 to 1.

Code sample:

Genderize Full Name Geo code sample for shell:

curl --request POST \ 
--url https://v2.namsor.com/NamSorAPIv2/api2/json/genderFullGeoBatch \
--header 'X-API-KEY: your-api-key' \
--header 'Accept: application/json'
--header 'Content-Type: application/json' \
--data '{"personalNames":[{"id":"3a2d203a-a6a4-42f9-acd1-1b5c56c7d39f","name":"Keith Haring","countryIso2":"US"}]}'

Body parameter:

{
  "personalNames": [
    {
      "id": "3a2d203a-a6a4-42f9-acd1-1b5c56c7d39f",
      "name": "Keith Haring",
      "countryIso2": "US"
    }
  ]
}

The above command returns JSON structured like this:

{
    "personalNames": [
        {
            "script": "LATIN",
            "id": "3a2d203a-a6a4-42f9-acd1-1b5c56c7d39f",
            "name": "Keith Haring",
            "likelyGender": "male",
            "genderScale": -0.8716298606148474,
            "score": 11.225679376737641,
            "probabilityCalibrated": 0.9358149303074237
        }
    ]
}

Genderize Full Name Geo code sample for java:

HttpResponse<String> response = Unirest.post("https://v2.namsor.com/NamSorAPIv2/api2/json/genderFullGeoBatch")
.header("X-API-KEY", "your-api-key")
.header("Accept", "application/json")
.header("Content-Type", "application/json")
.body("{\"personalNames\":[{\"id\":\"3a2d203a-a6a4-42f9-acd1-1b5c56c7d39f\",\"name\":\"Keith Haring\",\"countryIso2\":\"US\"}]}")
.asString();

Body parameter:

{
  "personalNames": [
    {
      "id": "3a2d203a-a6a4-42f9-acd1-1b5c56c7d39f",
      "name": "Keith Haring",
      "countryIso2": "US"
    }
  ]
}

The above command returns JSON structured like this:

{
    "personalNames": [
        {
            "script": "LATIN",
            "id": "3a2d203a-a6a4-42f9-acd1-1b5c56c7d39f",
            "name": "Keith Haring",
            "likelyGender": "male",
            "genderScale": -0.8716298606148474,
            "score": 11.225679376737641,
            "probabilityCalibrated": 0.9358149303074237
        }
    ]
}

Genderize Full Name Geo code sample for python:

import requests

url = "https://v2.namsor.com/NamSorAPIv2/api2/json/genderFullGeoBatch"

payload = {
  "personalNames": [
    {
      "id": "3a2d203a-a6a4-42f9-acd1-1b5c56c7d39f",
      "name": "Keith Haring",
      "countryIso2": "US"
    }
  ]
}
headers = {
    "X-API-KEY": "your-api-key",
    "Accept": "application/json",
    "Content-Type": "application/json"
}

response = requests.request("POST", url, json=payload, headers=headers)

print(response.text)

Body parameter:

{
  "personalNames": [
    {
      "id": "3a2d203a-a6a4-42f9-acd1-1b5c56c7d39f",
      "name": "Keith Haring",
      "countryIso2": "US"
    }
  ]
}

The above command returns JSON structured like this:

{
    "personalNames": [
        {
            "script": "LATIN",
            "id": "3a2d203a-a6a4-42f9-acd1-1b5c56c7d39f",
            "name": "Keith Haring",
            "likelyGender": "male",
            "genderScale": -0.8716298606148474,
            "score": 11.225679376737641,
            "probabilityCalibrated": 0.9358149303074237
        }
    ]
}

Genderize Full Name Geo code sample for javascript:

const response = await fetch("https://v2.namsor.com/NamSorAPIv2/api2/json/genderFullGeoBatch", {
  "method": "POST",
  "headers": {
    "X-API-KEY": "your-api-key",
    "Accept": "application/json",
    "Content-Type": "application/json"
  },
  "body": JSON.stringify({
  "personalNames": [
    {
      "id": "3a2d203a-a6a4-42f9-acd1-1b5c56c7d39f",
      "name": "Keith Haring",
      "countryIso2": "US"
    }
  ]
})
});

if (response.ok) {
  const data = await response.json(); // Extract JSON data from response
  console.log(data); // View data in the console
} else {
  console.error("The request failed with status:", response.status, response);
}

Body parameter:

{
  "personalNames": [
    {
      "id": "3a2d203a-a6a4-42f9-acd1-1b5c56c7d39f",
      "name": "Keith Haring",
      "countryIso2": "US"
    }
  ]
}

The above command returns JSON structured like this:

{
    "personalNames": [
        {
            "script": "LATIN",
            "id": "3a2d203a-a6a4-42f9-acd1-1b5c56c7d39f",
            "name": "Keith Haring",
            "likelyGender": "male",
            "genderScale": -0.8716298606148474,
            "score": 11.225679376737641,
            "probabilityCalibrated": 0.9358149303074237
        }
    ]
}
  • Precision:Precision gauge
  • Cost: 1 credit per name.
  • Description: Returns the most likely gender of an unsplit full name, according to its geographic context.
information

For requests with a GET method all parameters are required. For more ease in the use of our requests we recommend that you use the POST method.

HTTP request

http request
GET
https://v2.namsor.com/NamSorAPIv2/api2/json/genderFullGeo/{name}/{countryIso2}
Request header
PropertyRequiredDescription
X-API-KEYRequiredYour Namsor's services API key
information

To get an API key for free, please create an account.

Request parameters
NameTypeRequiredDescription
nameStringRequiredUnsplit full name (first name and last name).
countryIso2StringRequiredCountry of residence, in ISO 3166-1 alpha-2 format.
Response
NameTypeDescriptionEnumerators
scriptStringName of the script used for the name, in ISO 15924 format.Script
idStringProvided unique identifier.
nameStringSubmitted full name.
likelyGenderStringMost likely gender.Genders
genderScaleNumberGender scale ranging from -1 (male) to +1 (female).
scoreNumberHigher implies a more reliable result, score is not normalized.
probabilityCalibratedNumberHigher implies a more reliable result, ranges from 0 to 1.

Code sample:

Genderize Full Name Geo code sample for shell:

curl --request GET \ 
--url https://v2.namsor.com/NamSorAPIv2/api2/json/genderFullGeo/Keith%20Haring/US \
--header 'X-API-KEY: your-api-key' \
--header 'Accept: application/json'

The above command returns JSON structured like this:

{
    "script": "LATIN",
    "id": "3a2d203a-a6a4-42f9-acd1-1b5c56c7d39f",
    "name": "Keith Haring",
    "likelyGender": "male",
    "genderScale": -0.8716298606148474,
    "score": 11.225679376737641,
    "probabilityCalibrated": 0.9358149303074237
}

Genderize Full Name Geo code sample for java:

HttpResponse<String> response = Unirest.get("https://v2.namsor.com/NamSorAPIv2/api2/json/genderFullGeo/Keith%20Haring/US")
.header("X-API-KEY", "your-api-key")
.header("Accept", "application/json")
.asString();

The above command returns JSON structured like this:

{
    "script": "LATIN",
    "id": "3a2d203a-a6a4-42f9-acd1-1b5c56c7d39f",
    "name": "Keith Haring",
    "likelyGender": "male",
    "genderScale": -0.8716298606148474,
    "score": 11.225679376737641,
    "probabilityCalibrated": 0.9358149303074237
}

Genderize Full Name Geo code sample for python:

import requests

url = "https://v2.namsor.com/NamSorAPIv2/api2/json/genderFullGeo/Keith%20Haring/US"

headers = {
  "X-API-KEY": "your-api-key",
 "Accept": "application/json"
}

response = requests.request("GET", url, headers=headers)

print(response.text)

The above command returns JSON structured like this:

{
    "script": "LATIN",
    "id": "3a2d203a-a6a4-42f9-acd1-1b5c56c7d39f",
    "name": "Keith Haring",
    "likelyGender": "male",
    "genderScale": -0.8716298606148474,
    "score": 11.225679376737641,
    "probabilityCalibrated": 0.9358149303074237
}

Genderize Full Name Geo code sample for javascript:

const response = await fetch("https://v2.namsor.com/NamSorAPIv2/api2/json/genderFullGeo/Keith%20Haring/US", {
  "method": "GET",
  "headers": {
    "X-API-KEY": "your-api-key",
    "Accept": "application/json"
  }
});

if (response.ok) {
  const data = await response.json(); // Extract JSON data from response
  console.log(data); // View data in the console
} else {
  console.error("The request failed with status:", response.status, response);
}

The above command returns JSON structured like this:

{
    "script": "LATIN",
    "id": "3a2d203a-a6a4-42f9-acd1-1b5c56c7d39f",
    "name": "Keith Haring",
    "likelyGender": "male",
    "genderScale": -0.8716298606148474,
    "score": 11.225679376737641,
    "probabilityCalibrated": 0.9358149303074237
}