# Welcome to Haystack!

Haystack provides modular search for Django. It features a unified, familiar API that allows you to plug in different search backends (such as Solr, Elasticsearch, Whoosh, Xapian, etc.) without having to modify your code.

Note

This documentation represents the current version of Haystack. For old versions of the documentation:

- v2.5.X: https://django-haystack.readthedocs.io/en/v2.5.1/

- v2.4.X: https://django-haystack.readthedocs.io/en/v2.4.1/

- v2.3.X: https://django-haystack.readthedocs.io/en/v2.3.0/

- v2.2.X: https://django-haystack.readthedocs.io/en/v2.2.0/

- v2.1.X: https://django-haystack.readthedocs.io/en/v2.1.0/

- v2.0.X: https://django-haystack.readthedocs.io/en/v2.0.0/

- v1.2.X: https://django-haystack.readthedocs.io/en/v1.2.7/

- v1.1.X: https://django-haystack.readthedocs.io/en/v1.1/

## Getting Started

If you’re new to Haystack, you may want to start with these documents to get you up and running:

- Getting Started with Haystack
  - Installation
  - Configuration
  - Handling Data
  - Setting Up The Views
  - Complete!
  - What’s Next?

- Views & Forms
- Template Tags
- Glossary
- Management Commands
- (In)Frequently Asked Questions
- Haystack-Related Applications
- Installing Search Engines
- Debugging Haystack
- Changelog
- Contributing
- Python 3 Support
- Migrating From Haystack 1.X to Haystack 2.X

## Advanced Uses

Once you’ve got Haystack working, here are some of the more complex features you may want to include in your application.

- Best Practices
- Highlighting
- Faceting
- Autocomplete
- Boost
- Signal Processors
- Multiple Indexes
- Rich Content Extraction
- Spatial Search
- Django Admin Search

## Reference

If you’re an experienced user and are looking for a reference, you may be looking for API documentation and advanced usage as detailed in:

- `SearchQuerySet` API
  - `SearchQuerySet`
  - Why Follow `QuerySet`?
  - Quick Start
  - `SearchQuerySet`
  - The `content` Shortcut
  - `SearchQuerySet` Methods
  - `EmptySearchQuerySet`
  - `RelatedSearchQuerySet`
- `SearchIndex` API
  - `SearchIndex`
  - Quick Start
  - Background
  - Keeping The Index Fresh
  - Advanced Data Preparation
  - Adding New Fields
  - `Search Index`
  - `ModelSearchIndex`
- Input Types
  - Available Input Types
  - Creating Your Own Input Types
- `SearchField` API
  - `SearchField`
  - Subclasses
  - Usage
  - Field Options
  - Method Reference
- `SearchResult` API
  - `SearchResult`
  - Attribute Reference
  - Method Reference
- `SearchQuery` API
  - `SearchQuery`
  - `SQ` Objects
  - Backend-Specific Methods
  - Inheritable Methods
- `SearchBackend` API
  - `SearchBackend`
  - Method Reference
- Architecture Overview
  - `SearchQuerySet`
  - `SearchQuery`
  - `SearchBackend`
  - `SearchSite`
  - `SearchIndex`
- Backend Support
  - Supported Backends
  - Backend Capabilities
  - Backend Support Matrix
  - Unsupported Backends & Alternatives
- Haystack Settings
  - `HAYSTACK_DEFAULT_OPERATOR`
  - `HAYSTACK_CONNECTIONS`
  - `HAYSTACK_ROUTERS`
  - `HAYSTACK_SIGNAL_PROCESSOR`
  - `HAYSTACK_DOCUMENT_FIELD`
  - `HAYSTACK_SEARCH_RESULTS_PER_PAGE`
  - `HAYSTACK_CUSTOM_HIGHLIGHTER`
  - `HAYSTACK_ITERATOR_LOAD_PER_QUERY`
  - `HAYSTACK_LIMIT_TO_REGISTERED_MODELS`
  - `HAYSTACK_ID_FIELD`
  - `HAYSTACK_DJANGO_CT_FIELD`
  - `HAYSTACK_DJANGO_ID_FIELD`
  - `HAYSTACK_IDENTIFIER_METHOD`
  - `HAYSTACK_FUZZY_MIN_SIM`
  - `HAYSTACK_FUZZY_MAX_EXPANSIONS`
- Utilities
  - `get_identifier`

## Developing

Finally, if you’re looking to help out with the development of Haystack, the following links should help guide you on running tests and creating additional backends:

- Running Tests
- Creating New Backends

## Requirements

Haystack has a relatively easily-met set of requirements.

- Python 3.8+

- Django 3-5

Additionally, each backend has its own requirements. You should refer to Installing Search Engines for more details.