Skip to content

streetSuffix - suffix abbreviation (US) #3703

Open

Description

@michael-hart-github

Clear and concise description of the problem

Note

I haven't made many public-facing issues before. If it's hard to figure out what I'm requesting, please let me know! 😄

When creating fake addresses, I may not want values of 123 Fake Street or 123 Fake.

Instead, I might specifically want/need:

  • 123 Fake St
  • Or, 123 Fake St.

Suggested solution

Some kind of modification to streetAddress(), or street(), that allows for abbreviated suffixes would be great.

Calling faker.location.streetAddress({ useSuffixAbbreviate: true }) returns something like 123 Fake St
And if it's set to ({ useSuffixAbbreviate: false }), it could return 123 Fake St. instead.

This would apply to multiple street name suffixes, such as:
Avenue = Ave
Center = Ctr
Circle = Cir
Street = St
Etc.

function streetAddress(
  options:
    | boolean
    | {
        useFullAddress?: boolean;
      } = {}
    | {
        useSuffixAbbreviate?: boolean;
      } = {}
): string;

So examples would look something like:

faker.location.streetAddress() // '0917 O'Conner Estates'
faker.location.streetAddress(false) // '34830 Erdman Hollow'
faker.location.streetAddress(true) // '3393 Ronny Way Apt. 742'
faker.location.streetAddress({ useFullAddress: true }) // '7917 Miller Park Apt. 410'
faker.location.streetAddress({ useSuffixAbbreviate: true }) // '732 Forest Rd'
faker.location.streetAddress({ useFullAddress: true }, { useSuffixAbbreviate: true }) // '347 Maple Ave Apt. 99'

Alternative

An alternative might be a new listing under location, called streetSuffix() would work, if its easier to implement.

It would just be good to have some way to get street addresses, with abbreviated suffixes both with, and without periods.

Additional context

Reference material

A full list of US street suffixes and standardized abbreviations are available here via USPS.

For cases where multiple listings are possible (Example: AVENUE = AV, AVE, AVN, etc.) the Postal Service Standard Suffix Abbreviation (should probably?) win any tie breakers. The logic being that the work being done will presumably in some way relate to mailing or legal addresses, so following USPS standards would be generally preferable for the sake of standardization.

Activity

  1. github-actions commented on Jan 23, 2026

    @github-actions
    Contributor

    Thank you for your feature proposal.

    We marked it as "waiting for user interest" for now to gather some feedback from our community:

    • If you would like to see this feature be implemented, please react to the description with an up-vote (:+1:).
    • If you have a suggestion or want to point out some special cases that need to be considered, please leave a comment, so we are aware about them.

    We would also like to hear about other community members' use cases for the feature to give us a better understanding of their potential implicit or explicit requirements.

    We will start the implementation based on:

    • the number of votes ( 👍 ) and comments
    • the relevance for the ecosystem
    • availability of alternatives and workarounds
    • and the complexity of the requested feature

    We do this because:

    • There are plenty of languages/countries out there and we would like to ensure that every method can cover all or almost all of them.
    • Every feature we add to faker has "costs" associated to it:
      • initial costs: design, implementation, reviews, documentation
      • running costs: awareness of the feature itself, more complex module structure, increased bundle size, more work during refactors

    View more issues which are waiting for user interest

  2. xDivisionByZerox commented on Jan 24, 2026

    @xDivisionByZerox
    Member

    @michael-hart-github I see that you gave a reaction ( 👍 emoji ) to the comment of the bot. When filtering in GitHub, only reactions on the issue itself are respected. Currently your upvote would not be tracked.
    Please give the reaction on the issue you created (yes it is totally valid to upvote your own feature requests).

    Otherwise, I'm able to understand the core of your request (since you made the explicit note that it might not be). The reference material you linked, help to understand of what you whish to achieve.

  3. matthewmayer commented on Jan 24, 2026

    @matthewmayer
    Contributor

    Would need to consider how this works in other locales as they may not have similar abbreviations (and they might not be suffixes but eg prefixes)

  4. matthewmayer commented on Jan 26, 2026

    @matthewmayer
    Contributor

    This would probably need to be present in both location.street() and location.streetAddress()

    Parameter name could be abbreviated for consistency with location.cardinalDirection, faker.date.month, faker.location.state etc and to avoid "suffix", that way e.g. in es locale, Avenida Patricia could be Av. Patricia when abbreviated.

  5. michael-hart-github commented on Jan 26, 2026

    @michael-hart-github
    Author

    I see that you gave a reaction ( 👍 emoji ) to the comment of the bot.

    Hah, whoops! Thanks for that @xDivisionByZerox! Fixed.

    Would need to consider how this works in other locales as they may not have similar abbreviations (and they might not be suffixes but eg prefixes)

    Ah, very true! I wasn't sure if that is exactly why something like this hadn't be performed already; I figured that most languages/countries probably do some variation of abbreviation for street address names. I recall seeing in the documentation that something like 70 different localizations are available? If this is too big of a task to have done, I will understand. Worst comes to worst, I can put together a few variations of street, circle, drive, road, etc. in abbreviated form and combine that with some of the other FakerJS elements for my specific use-case. It would be a "nice to have" if this were possible out of the box, however. Perhaps a of meidum-term goal at some point.

    If any users reading this have a kind of homebrew solution they have already made and use, it may be helpful to include for myself and others in the meantime as a GH gist. It could certainly give people a good starting point to build from for various locales.

    For a bit of background: This repo is (at least partially...?) used in Postman, which is how I came across this project. I had been a little surprised that Postman didn't have it abbreviated suffixes, and only realized how huge the request might be, the more I had looked into the documentation. Haha.😄

  6. added
    m: locationSomething is referring to the location module
    on Feb 27, 2026
  7. ST-DDT commented on Feb 27, 2026

    @ST-DDT
    Member

    For a bit of background: This repo is (at least partially...?) used in Postman, which is how I came across this project. I had been a little surprised that Postman didn't have it abbreviated suffixes, and only realized how huge the request might be, the more I had looked into the documentation. Haha.😄

    Note: AFAICT postman uses an ancient version of faker IIRC v5.5.3 (current is v10.3.0).

    If you use the $randomStreet placeholders, then this change will not apply anyway.
    If you use faker.location.streetName(), then you could create a copy of faker and replace the street suffixes with abbreviations.

    https://github.com/faker-js/faker/blob/next/src/locales/en/location/street_suffix.ts

    See this docs for info on how to create a custom faker instance:

    https://fakerjs.dev/guide/localization.html#custom-locales-and-fallbacks

  8. michael-hart-github commented on Feb 28, 2026

    @michael-hart-github
    Author

    Thanks for the info @ST-DDT!

    In-between my initial request and now, I was trying to get an updated version of FakerJS working in Postman due to the same reasons you had mentioned.

    Here is what I ended up coming up with.

  9. ST-DDT commented on Feb 28, 2026

    @ST-DDT
    Member

    @faker-js/maintainers do you think this might be a good addition for our docs? Aka using faker with postman?
    @michael-hart-github would you like to contribute that?

    https://github.com/faker-js/faker/blob/next/docs/guide/frameworks.md

  10. michael-hart-github commented on Mar 12, 2026

    @michael-hart-github
    Author

    @ST-DDT Sorry for the delay. I'd be happy to contribute to it.

    I'll try to find some time this weekend to submit a PR for it.

  11. added this to the v10.x milestone on Jun 22, 2026
  12. modified the milestones: v10.x, vFuture on Jul 5, 2026
  13. added 3 commits that reference this issue on Jul 20, 2026
    6a978f9
    b3a5abd
    21066b1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    c: featureRequest for new featurehas workaroundWorkaround provided or linkedm: locationSomething is referring to the location modules: waiting for user interestWaiting for more users interested in this feature

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions