http
A composable, multi-platform, Future-based API for HTTP requests.
1.6.0
1.0M downloads/mo
#1 most downloaded on pub.dev
dart-lang/http
What this package is like to depend on
Last release 9 months ago
10 Nov 2025
Ships fairly regularly
a new release about every 2 months
Some releases are documented
notes for 48 of 127 stable releases
Nothing withdrawn
no release was ever pulled
14 years old
130 releases · first in 2012
1 release in the last 12 months
see the full history below
Release timeline
130 releases · Nov 2012 to Nov 2025Releases
latest 60 of 130-
1.6.010 Nov 2025Release notes
Open source →- Breaking Change the behavior of
Request.bodyso that a charset parameter is only added for text and XML media types. This brings the behavior ofpackage:httpin line with RFC-8259. - On the web, fix cancellations for
StreamSubscriptions of response bodies waiting for the next chunk. - Export
MediaTypefrompackage:http_parser. - Added a section on testing to
README.md.
- Breaking Change the behavior of
-
1.5.007 Aug 2025Release notes
Open source →- Fixed a bug in
IOClientwhere theHttpClient's response stream was
cancelled after the response stream was completed. - Added support for aborting requests before they complete.
- Clarify that some header names may not be sent/received.
Release notes
Open source →- Fixed a bug in
IOClientwhere theHttpClient's response stream was cancelled after the response stream was completed. - Added support for aborting requests before they complete.
- Clarify that some header names may not be sent/received.
- Fixed a bug in
-
1.5.0-beta.215 Jul 2025 pre-releaseNothing published for this version
-
1.5.0-beta08 Jul 2025 pre-releaseNothing published for this version
-
1.4.006 May 2025Release notes
Open source →- Fixed default encoding for application/json without a charset to use utf8 instead of latin1, ensuring proper JSON decoding.
- Avoid references to
windowinBrowserClient, restoring support for web workers and NodeJS.
-
1.3.021 Jan 2025Release notes
Open source →- Fixed unintended HTML tags in doc comments.
- Switched
BrowserClientto use Fetch API instead ofXMLHttpRequest.
Release notes
Open source →- Fixed unintended HTML tags in doc comments.
- Switched
BrowserClientto use Fetch API instead ofXMLHttpRequest.
-
1.2.216 Jul 2024 -
1.2.115 Feb 2024 -
1.2.016 Jan 2024Release notes
Open source →- Add
MockClient.pngResponse, which makes it easier to fake image responses. - Added the ability to fetch the URL of the response through
BaseResponseWithUrl. - Add the ability to get headers as a
Map<String, List<String>toBaseResponse.
- Add
-
1.1.227 Nov 2023 -
1.1.121 Nov 2023Release notes
Open source →BrowserClientthrowsClientExceptionwhen the'Content-Length'header is invalid.IOClienttrims trailing whitespace on header values.- Require Dart 3.2
- Browser: support Wasm by using
package:web.
-
1.1.026 Jun 2023Release notes
Open source →- Add better error messages for
SocketExceptions when usingIOClient. - Make
StreamedRequest.sinkaStreamSink. This makesrequest.sink.close()return aFutureinstead ofvoid, but the returned future should not be awaited. The Future returned fromsink.close()may only complete after the request has been sent.
- Add better error messages for
-
1.0.022 May 2023Release notes
Open source →- Requires Dart 3.0 or later.
- Add
base,final, andinterfacemodifiers to some classes.
-
0.13.601 May 2023Release notes
Open source →BrowserClientthrows an exception ifsendis called afterclose.- If
no_default_http_client=trueis set in the environment then disk usage is reduced in some circumstances. - Require Dart 2.19
-
0.13.503 Aug 2022Release notes
Open source →- Allow async callbacks in RetryClient.
- In
MockHttpClientuse the callback returnedResponse.requestinstead of the argument value to give more control to the callback. This may be breaking for callbacks which return incomplete Responses and relied on the default.
-
0.13.404 Oct 2021Release notes
Open source →- Throw a more useful error when a client is used after it has been closed.
- Require Dart 2.14.
-
0.13.303 May 2021 -
0.13.228 Apr 2021Release notes
Open source →- Add
package:http/retry.dartwithRetryClient. This is the same implementation aspackage:http_retrywhich will be discontinued.
- Add
-
0.13.119 Mar 2021 -
0.13.005 Feb 2021Release notes
Open source →- Migrate to null safety.
- Add
constconstructor toByteStream. - Migrate
BrowserClientfromblobtoarraybuffer. - Breaking All APIs which previously allowed a
StringorUrito be passed now require aUri. - Breaking Added a
bodyandencodingargument toClient.delete. This is only breaking for implementations which override that method.
-
0.13.0-nullsafety.029 Jan 2021 pre-releaseNothing published for this version
-
0.12.216 Jul 2020Release notes
Open source →- Fix error handler callback type for response stream errors to avoid masking root causes.
-
0.12.127 Apr 2020Release notes
Open source →- Add
IOStreamedResponsewhich includes the ability to detach the socket. When sending a request with anIOClientthe response will be anIOStreamedResponse. - Remove dependency on
package:async.
- Add
-
0.12.018 Sep 2018Release notes
Open source →New Features
- The regular
Clientfactory constructor is now usable anywhere thatdart:ioordart:htmlare available, and will give you anIoClientorBrowserClientrespectively. - The
package:http/http.dartimport is now safe to use on the web (or anywhere that eitherdart:ioordart:htmlare available).
Breaking Changes
- In order to use or reference the
IoClientdirectly, you will need to import the newpackage:http/io_client.dartimport. This is typically only necessary if you are passing a customHttpClientinstance to the constructor, in which case you are already giving up support for web.
- The regular
-
0.12.0+108 Jan 2019Nothing published for this version
-
0.12.0+203 Apr 2019 -
0.12.0+326 Dec 2019 -
0.12.0+407 Jan 2020 -
0.11.320 Jul 2015Release notes
Open source →- Add a
Client.patchshortcut method and a matching top-levelpatchmethod.
- Add a
-
0.11.3+126 Aug 2015 -
0.11.3+228 Aug 2015Release notes
Open source →-
Require Dart SDK >= 1.9.0
-
Eliminate many uses of
Chain.trackfrom thestack_tracepackage.
-
-
0.11.3+314 Dec 2015 -
0.11.3+425 Apr 2016 -
0.11.3+526 Apr 2016 -
0.11.3+604 May 2016 -
0.11.3+705 May 2016 -
0.11.3+806 Jul 2016 -
0.11.3+919 Jul 2016 -
0.11.3+1106 Mar 2017Release notes
Open source →- Fix the SDK constraint to only include SDK versions that support importing
dart:ioeverywhere.
- Fix the SDK constraint to only include SDK versions that support importing
-
0.11.3+1207 Mar 2017Release notes
Open source →- Don't quote the boundary header for
MultipartRequest. This is more compatible with server quirks.
- Don't quote the boundary header for
-
0.11.3+1330 Mar 2017 -
0.11.3+1420 Jul 2017Release notes
Open source →- Remove single quote ("'" - ASCII 39) from boundary characters. Causes issues with Google Cloud Storage.
-
0.11.3+1527 Sep 2017 -
0.11.3+1613 Oct 2017 -
0.11.3+1709 Jul 2018Release notes
Open source →- Use new Dart 2 constant names. This branch is only for allowing existing code to keep running under Dart 2.
-
0.11.206 Apr 2015 -
0.11.119 May 2014 -
0.11.1+102 Jun 2014 -
0.11.1+321 Feb 2015 -
0.11.005 May 2014Release notes
Open source →-
The package no longer depends on
dart:io. TheBrowserClientclass inpackage:http/browser_client.dartcan now be used to make requests on the browser. -
Change
MultipartFile.contentTypefromdart:io'sContentTypetype tohttp_parser'sMediaTypetype. -
Exceptions are now of type
ClientExceptionrather thandart:io'sHttpException.
-
-
0.11.0+105 May 2014Release notes
Open source →- Fix a bug in handling errors in decoding XMLHttpRequest responses for
BrowserClient.
- Fix a bug in handling errors in decoding XMLHttpRequest responses for
-
0.10.031 Mar 2014Release notes
Open source →-
Make
BaseRequest.contentLengthandBaseResponse.contentLengthusenullto indicate an unknown content length rather than -1. -
The
contentLengthparameter tonew BaseResponseis now named rather than positional. -
Make request headers case-insensitive.
-
Make
MultipartRequestmore closely adhere to browsers' encoding conventions.
-
-
0.9.210 Dec 2013Nothing published for this version
-
0.9.2+113 Jan 2014Nothing published for this version
-
0.9.2+316 Jan 2014Nothing published for this version
-
0.9.109 Dec 2013Nothing published for this version
-
0.9.006 Nov 2013Nothing published for this version
-
0.8.1001 Nov 2013Nothing published for this version
-
0.8.10+304 Nov 2013Nothing published for this version
-
0.8.10+405 Nov 2013Nothing published for this version