You can upload files directly to an instance or connect an external data source.
| Data Source | Description |
|---|---|
| Built-in storage | Upload files directly to an instance. Available by default on every instance. |
| Website | Connect a domain you own to index website pages. |
| R2 Bucket | Connect a Cloudflare R2 bucket to index stored documents. |
AI Search can ingest a variety of file types. The following plain text files and rich format files are supported.
| Format | File extensions | Mime Type |
|---|---|---|
| Text | .txt, .rst |
text/plain |
| Log | .log, .log.gz |
text/plain |
| Config | .ini, .conf, .env, .properties, .gitignore, .editorconfig, .toml |
text/plain, text/toml |
| Markdown | .markdown, .md, .mdx, .mdoc |
text/markdown |
| LaTeX | .tex, .latex |
application/x-tex, application/x-latex |
| Script | .sh, .bat, .ps1 |
application/x-sh, application/x-msdos-batch, text/x-powershell |
| SGML | .sgml |
text/sgml |
| JSON | .json |
application/json |
| SQL | .sql |
application/sql |
| YAML | .yaml, .yml |
application/x-yaml |
| CSS | .css |
text/css |
| JavaScript | .js |
application/javascript |
| PHP | .php |
application/x-httpd-php |
| Python | .py |
text/x-python |
| Ruby | .rb |
text/x-ruby |
| Java | .java |
text/x-java-source |
| C | .c |
text/x-c |
| C++ | .cpp, .cxx |
text/x-c++ |
| C Header | .h, .hpp |
text/x-c-header |
| Go | .go |
text/x-go |
| Rust | .rs |
text/rust |
| Swift | .swift |
text/swift |
| Dart | .dart |
text/dart |
| EMACS Lisp | .el |
application/x-elisp, text/x-elisp, text/x-emacs-lisp |
AI Search uses Markdown Conversion to convert rich format files to markdown. The following table lists the supported formats that will be converted to Markdown:
Format | File extensions | Mime Types | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
PDF Documents |
|
| ||||||||||||
Images 1 |
|
| ||||||||||||
HTML Documents |
|
| ||||||||||||
XML Documents |
|
| ||||||||||||
Microsoft Office Documents |
|
| ||||||||||||
Open Document Format |
|
| ||||||||||||
CSV |
|
| ||||||||||||
Apple Documents |
|
|
1 Image conversion uses two Workers AI models for object detection and summarization. See Workers AI pricing for more details.
AI Search has a file size limit of up to 4 MB.
Files that exceed this limit will not be indexed and will show up in the error logs.